You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: API-Reference/Flow.Launcher.Plugin.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -14,15 +14,15 @@
14
14
| class [FlowLauncherQueryEventArgs](./Flow.Launcher.Plugin/FlowLauncherQueryEventArgs.md)||
15
15
| record [GlyphInfo](./Flow.Launcher.Plugin/GlyphInfo.md)| Text with FontFamily specified |
16
16
| interface [IAsyncPlugin](./Flow.Launcher.Plugin/IAsyncPlugin.md)| Asynchronous Plugin Model for Flow Launcher |
17
-
| interface [IAsyncReloadable](./Flow.Launcher.Plugin/IAsyncReloadable.md)| This interface is to indicate and allow plugins to asyncronously reload their in memory data cache or other mediums when user makes a new change that is not immediately captured. For example, for BrowserBookmark and Program plugin does not automatically detect when a user added a new bookmark or program, so this interface's function is exposed to allow user manually do the reloading after those new additions. The command that allows user to manual reload is exposed via Plugin.Sys, and it will call the plugins that have implemented this interface. |
17
+
| interface [IAsyncReloadable](./Flow.Launcher.Plugin/IAsyncReloadable.md)| This interface is to indicate and allow plugins to asynchronously reload their in memory data cache or other mediums when user makes a new change that is not immediately captured. For example, for BrowserBookmark and Program plugin does not automatically detect when a user added a new bookmark or program, so this interface's function is exposed to allow user manually do the reloading after those new additions. The command that allows user to manual reload is exposed via Plugin.Sys, and it will call the plugins that have implemented this interface. |
| interface [IFeatures](./Flow.Launcher.Plugin/IFeatures.md)| Base Interface for Flow's special plugin feature interface |
20
20
| interface [IPlugin](./Flow.Launcher.Plugin/IPlugin.md)| Synchronous Plugin Model for Flow Launcher |
21
21
| interface [IPluginI18n](./Flow.Launcher.Plugin/IPluginI18n.md)| Represent plugins that support internationalization |
22
22
| interface [IPublicAPI](./Flow.Launcher.Plugin/IPublicAPI.md)| Public APIs that plugin can use |
23
23
| interface [IReloadable](./Flow.Launcher.Plugin/IReloadable.md)| This interface is to indicate and allow plugins to synchronously reload their in memory data cache or other mediums when user makes a new change that is not immediately captured. For example, for BrowserBookmark and Program plugin does not automatically detect when a user added a new bookmark or program, so this interface's function is exposed to allow user manually do the reloading after those new additions. The command that allows user to manual reload is exposed via Plugin.Sys, and it will call the plugins that have implemented this interface. |
| interface [ISavable](./Flow.Launcher.Plugin/ISavable.md)| Save addtional plugin data. Inherit this interface if additional data e.g. cache needs to be saved, Otherwise if LoadSettingJsonStorage or SaveSettingJsonStorage has been callded, plugin settings will be automatically saved (see Flow.Launcher/PublicAPIInstance.SavePluginSettings) by Flow |
25
+
| interface [ISavable](./Flow.Launcher.Plugin/ISavable.md)| Save additional plugin data. Inherit this interface if additional data e.g. cache needs to be saved, Otherwise if LoadSettingJsonStorage or SaveSettingJsonStorage has been called, plugin settings will be automatically saved (see Flow.Launcher/PublicAPIInstance.SavePluginSettings) by Flow |
Copy file name to clipboardExpand all lines: API-Reference/Flow.Launcher.Plugin/IAsyncReloadable.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# IAsyncReloadable interface
2
2
3
-
This interface is to indicate and allow plugins to asyncronously reload their in memory data cache or other mediums when user makes a new change that is not immediately captured. For example, for BrowserBookmark and Program plugin does not automatically detect when a user added a new bookmark or program, so this interface's function is exposed to allow user manually do the reloading after those new additions. The command that allows user to manual reload is exposed via Plugin.Sys, and it will call the plugins that have implemented this interface.
3
+
This interface is to indicate and allow plugins to asynchronously reload their in memory data cache or other mediums when user makes a new change that is not immediately captured. For example, for BrowserBookmark and Program plugin does not automatically detect when a user added a new bookmark or program, so this interface's function is exposed to allow user manually do the reloading after those new additions. The command that allows user to manual reload is exposed via Plugin.Sys, and it will call the plugins that have implemented this interface.
Copy file name to clipboardExpand all lines: API-Reference/Flow.Launcher.Plugin/IPlugin.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
Synchronous Plugin Model for Flow Launcher
4
4
5
-
If the Querying or Init method requires high IO transmission or performaing CPU intense jobs (performing better with cancellation), please try the IAsyncPlugin interface
5
+
If the Querying or Init method requires high IO transmission or performing CPU intense jobs (performing better with cancellation), please try the IAsyncPlugin interface
Copy file name to clipboardExpand all lines: API-Reference/Flow.Launcher.Plugin/IPublicAPI.md
+5-5
Original file line number
Diff line number
Diff line change
@@ -17,19 +17,19 @@ public interface IPublicAPI
17
17
| [FuzzySearch](IPublicAPI/FuzzySearch.md)(…) | Fuzzy Search the string with the given query. This is the core search mechanism Flow uses |
18
18
| [GetAllPlugins](IPublicAPI/GetAllPlugins.md)() | Get all loaded plugins |
19
19
| [GetTranslation](IPublicAPI/GetTranslation.md)(…) | Get translation of current language You need to implement IPluginI18n if you want to support multiple languages for your plugin |
20
-
| [HttpDownloadAsync](IPublicAPI/HttpDownloadAsync.md)(…) | Download the specific url to a cretain file path |
21
-
| [HttpGetStreamAsync](IPublicAPI/HttpGetStreamAsync.md)(…) | Http download the spefic url and return as stream |
22
-
| [HttpGetStringAsync](IPublicAPI/HttpGetStringAsync.md)(…) | Http download the spefic url and return as string |
20
+
| [HttpDownloadAsync](IPublicAPI/HttpDownloadAsync.md)(…) | Download the specific url to a certain file path |
21
+
| [HttpGetStreamAsync](IPublicAPI/HttpGetStreamAsync.md)(…) | Http download the specific url and return as stream |
22
+
| [HttpGetStringAsync](IPublicAPI/HttpGetStringAsync.md)(…) | Http download the specific url and return as string |
23
23
| [LoadSettingJsonStorage<T>](IPublicAPI/LoadSettingJsonStorage.md)() |LoadJsonStoragefor current plugin's setting. This is the method used to load settings from json in Flow. When the file is not exist, it will create a new instance for the specific type. |
| [ReloadAllPluginData](IPublicAPI/ReloadAllPluginData.md)() |ReloadsanyPluginsthathavetheIReloadableimplemented. ItrefeshesPlugin's in memory data with new content added by user. |
32
+
| [ReloadAllPluginData](IPublicAPI/ReloadAllPluginData.md)() |ReloadsanyPluginsthathavetheIReloadableimplemented. ItrefreshesPlugin's in memory data with new content added by user. |
Copy file name to clipboardExpand all lines: API-Reference/Flow.Launcher.Plugin/IPublicAPI/LogException.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# IPublicAPI.LogException method
2
2
3
-
Log an Exception. Will throw if in debug mode so developer will be aware, otherwise logs the eror message. This is the primary logging method used for Flow
3
+
Log an Exception. Will throw if in debug mode so developer will be aware, otherwise logs the error message. This is the primary logging method used for Flow
Copy file name to clipboardExpand all lines: API-Reference/Flow.Launcher.Plugin/ISavable.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# ISavable interface
2
2
3
-
Save addtional plugin data. Inherit this interface if additional data e.g. cache needs to be saved, Otherwise if LoadSettingJsonStorage or SaveSettingJsonStorage has been callded, plugin settings will be automatically saved (see Flow.Launcher/PublicAPIInstance.SavePluginSettings) by Flow
3
+
Save additional plugin data. Inherit this interface if additional data e.g. cache needs to be saved, Otherwise if LoadSettingJsonStorage or SaveSettingJsonStorage has been called, plugin settings will be automatically saved (see Flow.Launcher/PublicAPIInstance.SavePluginSettings) by Flow
Copy file name to clipboardExpand all lines: develop-dotnet-plugins.md
+7-7
Original file line number
Diff line number
Diff line change
@@ -2,11 +2,11 @@ Flow is written in C#, so plugins written in .Net platform can directly communic
2
2
3
3
## Initialization
4
4
5
-
For C# Plugins, We recommand you use the [dotnet template](https://github.com/Flow-Launcher/dotnet-template) to generate a plugin template.
5
+
For C# Plugins, We recommend you use the [dotnet template](https://github.com/Flow-Launcher/dotnet-template) to generate a plugin template.
6
6
7
-
In order to be recongized as a Flow DotNet plugin, the directory needs to have at least two files
7
+
In order to be recognized as a Flow DotNet plugin, the directory needs to have at least two files
8
8
1.[`plugin.json`](plugin.json.md)
9
-
2. A Dotnet Assembly that implements **[IPlugin](API-Reference/Flow.Launcher.Plugin/iplugin.md)** or **[IAsyncPlugin](API-Reference/Flow.Launcher.Plugin/iasyncplugin.md)** (remember to refrence[Flow.Launcher.Plugin](https://www.nuget.org/packages/Flow.Launcher.Plugin/) by Nuget). The plugin template will add the reference and create a `Main.cs` that implements `IPlugin`.
9
+
2. A Dotnet Assembly that implements **[IPlugin](API-Reference/Flow.Launcher.Plugin/iplugin.md)** or **[IAsyncPlugin](API-Reference/Flow.Launcher.Plugin/iasyncplugin.md)** (remember to reference[Flow.Launcher.Plugin](https://www.nuget.org/packages/Flow.Launcher.Plugin/) by Nuget). The plugin template will add the reference and create a `Main.cs` that implements `IPlugin`.
10
10
11
11
Find our API Reference [here](API-Reference/)
12
12
@@ -21,13 +21,13 @@ The `Main`class that implements **[IPlugin](API-Reference/Flow.Launcher.Plugin/i
21
21
1.`void Init(PluginInitContext context)`
22
22
-[PluginInitContext](https://github.com/Flow-Launcher/Flow.Launcher/blob/master/API-Reference/Flow.Launcher.Plugin/PluginInitContext.cs) exposes some API from Flow and an metadata object for your plugin.
23
23
- It will be invoked before the invocation of `Query`, so you can do some preparation here.
24
-
- We recommand you do expensive operations in this method instead of Object Constructor because this method will be executed in parallel with other plugins.
24
+
- We recommend you do expensive operations in this method instead of Object Constructor because this method will be executed in parallel with other plugins.
25
25
2.`List<Result> Query(Query query)`
26
26
-`Query` will be invoked when user activate this plugin with specific ActionKeyword.
27
27
- A `List` of [Result](/API-Reference/Flow.Launcher.Plugin/result.md) object should be returned.
28
28
29
29
**[IAsyncPlugin](API-Reference/Flow.Launcher.Plugin/iasyncplugin.md)** is the async version of **[IPlugin](API-Reference/Flow.Launcher.Plugin/iplugin.md)**
30
-
- Instead of implmenting`Init` and `Query`, you will need to implement `InitAsync`and `QueryAsync`, which use `Task`,`Task<List<Result>` as return value to allow using `async/await` strategy
30
+
- Instead of implementing`Init` and `Query`, you will need to implement `InitAsync`and `QueryAsync`, which use `Task`,`Task<List<Result>` as return value to allow using `async/await` strategy
31
31
-`QueryAsync` provides a `CancellationToken token` to allow you to check whether user has typed a new query.
32
32
33
33
@@ -48,8 +48,8 @@ The return value of `LoadContextMenus` is similar to Results from `Query/QueryAs
**IPluginI18n** means the plugin has been internationalized. Therefore, Flow will load the additional lauguage resources from `/Languages` when loading the plugin.
52
-
By implementing this interface with additional language files, Flow will be able to load plugin-sepcified localized language resources. You will be able to get the translated text with `IPublicAPI.GetTranslation(string key)`.
51
+
**IPluginI18n** means the plugin has been internationalized. Therefore, Flow will load the additional language resources from `/Languages` when loading the plugin.
52
+
By implementing this interface with additional language files, Flow will be able to load plugin-specific localized language resources. You will be able to get the translated text with `IPublicAPI.GetTranslation(string key)`.
Copy file name to clipboardExpand all lines: nodejs-develop-plugins.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -7,11 +7,11 @@ Although not a hard requirement, this guide will use Node.js to run the TypeScri
7
7
When building a Node.js plugins there are several things to be mindful of:
8
8
9
9
* The most important thing is we do not expect users to have to manually install the dependencies via npm because we aim to provide a seamless experience for them. This can be achieved by adding the following three things to your project:
10
-
1. Add a GitHub workflow- use a GitHub workflow that will install all your plugin's depedencies including the modules inside a folder called 'node_modules'.
10
+
1. Add a GitHub workflow- use a GitHub workflow that will install all your plugin's dependencies including the modules inside a folder called 'node_modules'.
11
11
2. Publish all as a zip- zip up your project including a lib directory that contains the modules and publish it to GitHub Releases page.
12
12
3. Point your module path to the node_modules directory- reference all the modules to that directory.
13
13
14
14
* Users can use their system-installed Node.js with Flow Launcher, but in most circumstances, they will most likely be using Flow Launcher's download of [Node.js](https://nodejs.org/dist/v16.18.0/node-v16.18.0-win-x64.zip)). This download of portable Node.js version is isolated from the user's system and can be simply removed.
15
15
16
16
### Simple Example
17
-
Have a look at this simple example plugin [here](https://github.com/Flow-Launcher/Flow.Launcher.Plugin.HelloWorldNodeJS), notice it has a folder called '.github/workflows' and a file called 'Publish Release.yml'. This is the workflow file that GitHub Workflow uses to run the CICD for the project. Moving out of that folder you can go into the [main.js](https://github.com/Flow-Launcher/Flow.Launcher.Plugin.HelloWorldNodeJS/blob/main/main.js) file, this is the entry file for your plugin.
17
+
Have a look at this simple example plugin [here](https://github.com/Flow-Launcher/Flow.Launcher.Plugin.HelloWorldNodeJS), notice it has a folder called '.github/workflows' and a file called 'Publish Release.yml'. This is the workflow file that GitHub Workflow uses to run the CI/CD for the project. Moving out of that folder you can go into the [main.js](https://github.com/Flow-Launcher/Flow.Launcher.Plugin.HelloWorldNodeJS/blob/main/main.js) file, this is the entry file for your plugin.
0 commit comments