Skip to content

Commit d57eca2

Browse files
authored
Merge branch 'Flow-Launcher:dev' into Fix-'100%-CPU'-BrowserBookmark-issue
2 parents 19f37f4 + 1da7e1e commit d57eca2

File tree

94 files changed

+5226
-445
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

94 files changed

+5226
-445
lines changed

.github/actions/spelling/allow.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,4 @@ ssh
44
ubuntu
55
runcount
66
Firefox
7-
Português
8-
Português (Brasil)
7+
workaround

.github/actions/spelling/expect.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,3 +103,4 @@ Reloadable
103103
metadatas
104104
WMP
105105
VSTHRD
106+
CJK

.github/actions/spelling/patterns.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -134,3 +134,12 @@
134134
\bčeština\b
135135
\bPortuguês\b
136136
\bIoc\b
137+
\bXiao\s*He\b
138+
\bZi\s*Ran\s*Ma\b
139+
\bWei\s*Ruan\b
140+
\bZhi\s*Neng\s*ABC\b
141+
\bZi\s*Guang\s*Pin\s*Yin\b
142+
\bPin\s*Yin\s*Jia\s*Jia\b
143+
\bXing\s*Kong\s*Jian\s*Dao\b
144+
\bDa\s*Niu\b
145+
\bXiao\s*Lang\b

.github/workflows/default_plugins.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
- name: Setup .NET
1515
uses: actions/setup-dotnet@v4
1616
with:
17-
dotnet-version: 7.0.x
17+
dotnet-version: 9.0.x
1818

1919
- name: Update Plugins To Production Version
2020
run: |
@@ -42,7 +42,7 @@ jobs:
4242

4343
- name: Build BrowserBookmark
4444
run: |
45-
dotnet publish 'Plugins/Flow.Launcher.Plugin.BrowserBookmark/Flow.Launcher.Plugin.BrowserBookmark.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.BrowserBookmark"
45+
dotnet publish 'Plugins/Flow.Launcher.Plugin.BrowserBookmark/Flow.Launcher.Plugin.BrowserBookmark.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.BrowserBookmark"
4646
7z a -tzip "Flow.Launcher.Plugin.BrowserBookmark.zip" "./Flow.Launcher.Plugin.BrowserBookmark/*"
4747
rm -r "Flow.Launcher.Plugin.BrowserBookmark"
4848
@@ -66,7 +66,7 @@ jobs:
6666

6767
- name: Build Calculator
6868
run: |
69-
dotnet publish 'Plugins/Flow.Launcher.Plugin.Calculator/Flow.Launcher.Plugin.Calculator.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.Calculator"
69+
dotnet publish 'Plugins/Flow.Launcher.Plugin.Calculator/Flow.Launcher.Plugin.Calculator.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.Calculator"
7070
7z a -tzip "Flow.Launcher.Plugin.Calculator.zip" "./Flow.Launcher.Plugin.Calculator/*"
7171
rm -r "Flow.Launcher.Plugin.Calculator"
7272
@@ -90,7 +90,7 @@ jobs:
9090

9191
- name: Build Explorer
9292
run: |
93-
dotnet publish 'Plugins/Flow.Launcher.Plugin.Explorer/Flow.Launcher.Plugin.Explorer.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.Explorer"
93+
dotnet publish 'Plugins/Flow.Launcher.Plugin.Explorer/Flow.Launcher.Plugin.Explorer.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.Explorer"
9494
7z a -tzip "Flow.Launcher.Plugin.Explorer.zip" "./Flow.Launcher.Plugin.Explorer/*"
9595
rm -r "Flow.Launcher.Plugin.Explorer"
9696
@@ -114,7 +114,7 @@ jobs:
114114

115115
- name: Build PluginIndicator
116116
run: |
117-
dotnet publish 'Plugins/Flow.Launcher.Plugin.PluginIndicator/Flow.Launcher.Plugin.PluginIndicator.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.PluginIndicator"
117+
dotnet publish 'Plugins/Flow.Launcher.Plugin.PluginIndicator/Flow.Launcher.Plugin.PluginIndicator.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.PluginIndicator"
118118
7z a -tzip "Flow.Launcher.Plugin.PluginIndicator.zip" "./Flow.Launcher.Plugin.PluginIndicator/*"
119119
rm -r "Flow.Launcher.Plugin.PluginIndicator"
120120
@@ -138,7 +138,7 @@ jobs:
138138

139139
- name: Build PluginsManager
140140
run: |
141-
dotnet publish 'Plugins/Flow.Launcher.Plugin.PluginsManager/Flow.Launcher.Plugin.PluginsManager.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.PluginsManager"
141+
dotnet publish 'Plugins/Flow.Launcher.Plugin.PluginsManager/Flow.Launcher.Plugin.PluginsManager.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.PluginsManager"
142142
7z a -tzip "Flow.Launcher.Plugin.PluginsManager.zip" "./Flow.Launcher.Plugin.PluginsManager/*"
143143
rm -r "Flow.Launcher.Plugin.PluginsManager"
144144
@@ -162,7 +162,7 @@ jobs:
162162

163163
- name: Build ProcessKiller
164164
run: |
165-
dotnet publish 'Plugins/Flow.Launcher.Plugin.ProcessKiller/Flow.Launcher.Plugin.ProcessKiller.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.ProcessKiller"
165+
dotnet publish 'Plugins/Flow.Launcher.Plugin.ProcessKiller/Flow.Launcher.Plugin.ProcessKiller.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.ProcessKiller"
166166
7z a -tzip "Flow.Launcher.Plugin.ProcessKiller.zip" "./Flow.Launcher.Plugin.ProcessKiller/*"
167167
rm -r "Flow.Launcher.Plugin.ProcessKiller"
168168
@@ -186,7 +186,7 @@ jobs:
186186

187187
- name: Build Program
188188
run: |
189-
dotnet publish 'Plugins/Flow.Launcher.Plugin.Program/Flow.Launcher.Plugin.Program.csproj' --framework net7.0-windows10.0.19041.0 -c Release -o "Flow.Launcher.Plugin.Program"
189+
dotnet publish 'Plugins/Flow.Launcher.Plugin.Program/Flow.Launcher.Plugin.Program.csproj' --framework net9.0-windows10.0.19041.0 -c Release -o "Flow.Launcher.Plugin.Program"
190190
7z a -tzip "Flow.Launcher.Plugin.Program.zip" "./Flow.Launcher.Plugin.Program/*"
191191
rm -r "Flow.Launcher.Plugin.Program"
192192
@@ -210,7 +210,7 @@ jobs:
210210

211211
- name: Build Shell
212212
run: |
213-
dotnet publish 'Plugins/Flow.Launcher.Plugin.Shell/Flow.Launcher.Plugin.Shell.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.Shell"
213+
dotnet publish 'Plugins/Flow.Launcher.Plugin.Shell/Flow.Launcher.Plugin.Shell.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.Shell"
214214
7z a -tzip "Flow.Launcher.Plugin.Shell.zip" "./Flow.Launcher.Plugin.Shell/*"
215215
rm -r "Flow.Launcher.Plugin.Shell"
216216
@@ -234,7 +234,7 @@ jobs:
234234

235235
- name: Build Sys
236236
run: |
237-
dotnet publish 'Plugins/Flow.Launcher.Plugin.Sys/Flow.Launcher.Plugin.Sys.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.Sys"
237+
dotnet publish 'Plugins/Flow.Launcher.Plugin.Sys/Flow.Launcher.Plugin.Sys.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.Sys"
238238
7z a -tzip "Flow.Launcher.Plugin.Sys.zip" "./Flow.Launcher.Plugin.Sys/*"
239239
rm -r "Flow.Launcher.Plugin.Sys"
240240
@@ -258,7 +258,7 @@ jobs:
258258

259259
- name: Build Url
260260
run: |
261-
dotnet publish 'Plugins/Flow.Launcher.Plugin.Url/Flow.Launcher.Plugin.Url.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.Url"
261+
dotnet publish 'Plugins/Flow.Launcher.Plugin.Url/Flow.Launcher.Plugin.Url.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.Url"
262262
7z a -tzip "Flow.Launcher.Plugin.Url.zip" "./Flow.Launcher.Plugin.Url/*"
263263
rm -r "Flow.Launcher.Plugin.Url"
264264
@@ -282,7 +282,7 @@ jobs:
282282

283283
- name: Build WebSearch
284284
run: |
285-
dotnet publish 'Plugins/Flow.Launcher.Plugin.WebSearch/Flow.Launcher.Plugin.WebSearch.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.WebSearch"
285+
dotnet publish 'Plugins/Flow.Launcher.Plugin.WebSearch/Flow.Launcher.Plugin.WebSearch.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.WebSearch"
286286
7z a -tzip "Flow.Launcher.Plugin.WebSearch.zip" "./Flow.Launcher.Plugin.WebSearch/*"
287287
rm -r "Flow.Launcher.Plugin.WebSearch"
288288
@@ -306,7 +306,7 @@ jobs:
306306

307307
- name: Build WindowsSettings
308308
run: |
309-
dotnet publish 'Plugins/Flow.Launcher.Plugin.WindowsSettings/Flow.Launcher.Plugin.WindowsSettings.csproj' --framework net7.0-windows -c Release -o "Flow.Launcher.Plugin.WindowsSettings"
309+
dotnet publish 'Plugins/Flow.Launcher.Plugin.WindowsSettings/Flow.Launcher.Plugin.WindowsSettings.csproj' --framework net9.0-windows -c Release -o "Flow.Launcher.Plugin.WindowsSettings"
310310
7z a -tzip "Flow.Launcher.Plugin.WindowsSettings.zip" "./Flow.Launcher.Plugin.WindowsSettings/*"
311311
rm -r "Flow.Launcher.Plugin.WindowsSettings"
312312

.github/workflows/dotnet.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616

1717
runs-on: windows-latest
1818
env:
19-
FlowVersion: 1.19.5
19+
FlowVersion: 1.20.2
2020
NUGET_CERT_REVOCATION_MODE: offline
2121
BUILD_NUMBER: ${{ github.run_number }}
2222
steps:
@@ -31,7 +31,7 @@ jobs:
3131
- name: Setup .NET
3232
uses: actions/setup-dotnet@v4
3333
with:
34-
dotnet-version: 7.0.x
34+
dotnet-version: 9.0.x
3535
# cache: true
3636
# cache-dependency-path: |
3737
# Flow.Launcher/packages.lock.json

.github/workflows/spelling.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ jobs:
7272
steps:
7373
- name: check-spelling
7474
id: spelling
75-
uses: check-spelling/check-spelling@prerelease
75+
uses: check-spelling/check-spelling@v0.0.25
7676
with:
7777
suppress_push_for_open_pull_request: 1
7878
checkout: true
@@ -128,7 +128,7 @@ jobs:
128128
if: (success() || failure()) && needs.spelling.outputs.followup && contains(github.event_name, 'pull_request')
129129
steps:
130130
- name: comment
131-
uses: check-spelling/check-spelling@prerelease
131+
uses: check-spelling/check-spelling@v0.0.25
132132
with:
133133
checkout: true
134134
spell_check_this: check-spelling/spell-check-this@main

Flow.Launcher.Core/Configuration/Portable.cs

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,7 @@ public void DisablePortableMode()
4545
#endif
4646
IndicateDeletion(DataLocation.PortableDataPath);
4747

48-
API.ShowMsgBox("Flow Launcher needs to restart to finish disabling portable mode, " +
49-
"after the restart your portable data profile will be deleted and roaming data profile kept");
48+
API.ShowMsgBox(API.GetTranslation("restartToDisablePortableMode"));
5049

5150
UpdateManager.RestartApp(Constant.ApplicationFileName);
5251
}
@@ -69,8 +68,7 @@ public void EnablePortableMode()
6968
#endif
7069
IndicateDeletion(DataLocation.RoamingDataPath);
7170

72-
API.ShowMsgBox("Flow Launcher needs to restart to finish enabling portable mode, " +
73-
"after the restart your roaming data profile will be deleted and portable data profile kept");
71+
API.ShowMsgBox(API.GetTranslation("restartToEnablePortableMode"));
7472

7573
UpdateManager.RestartApp(Constant.ApplicationFileName);
7674
}
@@ -154,9 +152,8 @@ public void PreStartCleanUpAfterPortabilityUpdate()
154152
{
155153
FilesFolders.RemoveFolderIfExists(roamingDataDir, (s) => API.ShowMsgBox(s));
156154

157-
if (API.ShowMsgBox("Flow Launcher has detected you enabled portable mode, " +
158-
"would you like to move it to a different location?", string.Empty,
159-
MessageBoxButton.YesNo) == MessageBoxResult.Yes)
155+
if (API.ShowMsgBox(API.GetTranslation("moveToDifferentLocation"),
156+
string.Empty, MessageBoxButton.YesNo) == MessageBoxResult.Yes)
160157
{
161158
FilesFolders.OpenPath(Constant.RootDirectory, (s) => API.ShowMsgBox(s));
162159

@@ -169,8 +166,7 @@ public void PreStartCleanUpAfterPortabilityUpdate()
169166
{
170167
FilesFolders.RemoveFolderIfExists(portableDataDir, (s) => API.ShowMsgBox(s));
171168

172-
API.ShowMsgBox("Flow Launcher has detected you disabled portable mode, " +
173-
"the relevant shortcuts and uninstaller entry have been created");
169+
API.ShowMsgBox(API.GetTranslation("shortcutsUninstallerCreated"));
174170
}
175171
}
176172

@@ -181,9 +177,8 @@ public bool CanUpdatePortability()
181177

182178
if (roamingLocationExists && portableLocationExists)
183179
{
184-
API.ShowMsgBox(string.Format("Flow Launcher detected your user data exists both in {0} and " +
185-
"{1}. {2}{2}Please delete {1} in order to proceed. No changes have occurred.",
186-
DataLocation.PortableDataPath, DataLocation.RoamingDataPath, Environment.NewLine));
180+
API.ShowMsgBox(string.Format(API.GetTranslation("userDataDuplicated"),
181+
DataLocation.PortableDataPath, DataLocation.RoamingDataPath, Environment.NewLine));
187182

188183
return false;
189184
}

Flow.Launcher.Core/ExternalPlugins/PluginsManifest.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@ public static class PluginsManifest
2222
private static DateTime lastFetchedAt = DateTime.MinValue;
2323
private static readonly TimeSpan fetchTimeout = TimeSpan.FromMinutes(2);
2424

25+
// We should not initialize API in static constructor because it will create another API instance
26+
private static IPublicAPI api = null;
27+
private static IPublicAPI API => api ??= Ioc.Default.GetRequiredService<IPublicAPI>();
28+
2529
public static List<UserPlugin> UserPlugins { get; private set; }
2630

2731
public static async Task<bool> UpdateManifestAsync(bool usePrimaryUrlOnly = false, CancellationToken token = default)
@@ -46,7 +50,7 @@ public static async Task<bool> UpdateManifestAsync(bool usePrimaryUrlOnly = fals
4650
}
4751
catch (Exception e)
4852
{
49-
Ioc.Default.GetRequiredService<IPublicAPI>().LogException(ClassName, "Http request failed", e);
53+
API.LogException(ClassName, "Http request failed", e);
5054
}
5155
finally
5256
{

Flow.Launcher.Core/Flow.Launcher.Core.csproj

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>net7.0-windows</TargetFramework>
4+
<TargetFramework>net9.0-windows</TargetFramework>
55
<UseWpf>true</UseWpf>
66
<UseWindowsForms>true</UseWindowsForms>
77
<OutputType>Library</OutputType>
@@ -12,6 +12,7 @@
1212
<AppendRuntimeIdentifierToOutputPath>false</AppendRuntimeIdentifierToOutputPath>
1313
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
1414
<SatelliteResourceLanguages>en</SatelliteResourceLanguages>
15+
<RestorePackagesWithLockFile>true</RestorePackagesWithLockFile>
1516
</PropertyGroup>
1617

1718
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
@@ -57,6 +58,7 @@
5758
<PackageReference Include="FSharp.Core" Version="9.0.201" />
5859
<PackageReference Include="Meziantou.Framework.Win32.Jobs" Version="3.4.0" />
5960
<PackageReference Include="Microsoft.IO.RecyclableMemoryStream" Version="3.0.1" />
61+
<PackageReference Include="SemanticVersioning" Version="3.0.0" />
6062
<PackageReference Include="squirrel.windows" Version="1.5.2" NoWarn="NU1701" />
6163
<PackageReference Include="StreamJsonRpc" Version="2.21.10" />
6264
</ItemGroup>

0 commit comments

Comments
 (0)