Skip to content

Commit b7c6d62

Browse files
committed
Merge branch 'release/v8.23'
2 parents 41dfbb3 + aec621b commit b7c6d62

Some content is hidden

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

78 files changed

+1264
-784
lines changed

.github/workflows/ci.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
- name: Build
2323
run: dotnet build -c Release
2424
- name: Publish
25-
run: dotnet publish src/SourceGit.csproj -c Release -o publish -r win-x64 -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained
25+
run: dotnet publish src/SourceGit.csproj -c Release -o publish -r win-x64
2626
- name: Upload Artifact
2727
uses: actions/upload-artifact@v4
2828
with:
@@ -43,7 +43,7 @@ jobs:
4343
- name: Build
4444
run: dotnet build -c Release
4545
- name: Publish
46-
run: dotnet publish src/SourceGit.csproj -c Release -o publish -r osx-x64 -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained
46+
run: dotnet publish src/SourceGit.csproj -c Release -o publish -r osx-x64
4747
- name: Packing Program
4848
run: tar -cvf sourcegit.osx-x64.tar -C publish/ .
4949
- name: Upload Artifact
@@ -66,7 +66,7 @@ jobs:
6666
- name: Build
6767
run: dotnet build -c Release
6868
- name: Publish
69-
run: dotnet publish src/SourceGit.csproj -c Release -o publish -r osx-arm64 -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained
69+
run: dotnet publish src/SourceGit.csproj -c Release -o publish -r osx-arm64
7070
- name: Packing Program
7171
run: tar -cvf sourcegit.osx-arm64.tar -C publish/ .
7272
- name: Upload Artifact
@@ -89,7 +89,7 @@ jobs:
8989
- name: Build
9090
run: dotnet build -c Release
9191
- name: Publish
92-
run: dotnet publish src/SourceGit.csproj -c Release -o publish -r linux-x64 -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained
92+
run: dotnet publish src/SourceGit.csproj -c Release -o publish -r linux-x64
9393
- name: Rename Executable File
9494
run: mv publish/SourceGit publish/sourcegit
9595
- name: Packing Program

SourceGit.sln

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,15 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "SPECS", "SPECS", "{7802CD7A
7575
build\resources\rpm\SPECS\build.spec = build\resources\rpm\SPECS\build.spec
7676
EndProjectSection
7777
EndProject
78+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "appimage", "appimage", "{5D125DD9-B48A-491F-B2FB-D7830D74C4DC}"
79+
ProjectSection(SolutionItems) = preProject
80+
build\resources\appimage\publish-appimage = build\resources\appimage\publish-appimage
81+
build\resources\appimage\publish-appimage.conf = build\resources\appimage\publish-appimage.conf
82+
build\resources\appimage\runtime-x86_64 = build\resources\appimage\runtime-x86_64
83+
build\resources\appimage\sourcegit.appdata.xml = build\resources\appimage\sourcegit.appdata.xml
84+
build\resources\appimage\sourcegit.png = build\resources\appimage\sourcegit.png
85+
EndProjectSection
86+
EndProject
7887
Global
7988
GlobalSection(SolutionConfigurationPlatforms) = preSolution
8089
Debug|Any CPU = Debug|Any CPU
@@ -104,6 +113,7 @@ Global
104113
{F101849D-BDB7-40D4-A516-751150C3CCFC} = {9C2F0CDA-B56E-44A5-94B6-F3EA7AC20CDC}
105114
{9BA0B044-0CC9-46F8-B551-204F149BF45D} = {FD384607-ED99-47B7-AF31-FB245841BC92}
106115
{7802CD7A-591B-4EDD-96F8-9BF3F61692E4} = {9BA0B044-0CC9-46F8-B551-204F149BF45D}
116+
{5D125DD9-B48A-491F-B2FB-D7830D74C4DC} = {FD384607-ED99-47B7-AF31-FB245841BC92}
107117
EndGlobalSection
108118
GlobalSection(ExtensibilityGlobals) = postSolution
109119
SolutionGuid = {7FF1B9C6-B5BF-4A50-949F-4B407A0E31C9}

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
8.22.1
1+
8.23

build/build.osx.command

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,13 @@ cp resources/app/App.icns SourceGit.app/Contents/Resources/App.icns
99
sed "s/SOURCE_GIT_VERSION/${version}/g" resources/app/App.plist > SourceGit.app/Contents/Info.plist
1010

1111
mkdir -p SourceGit.app/Contents/MacOS
12-
dotnet publish ../src/SourceGit.csproj -c Release -r osx-arm64 -o SourceGit.app/Contents/MacOS -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained
12+
dotnet publish ../src/SourceGit.csproj -c Release -r osx-arm64 -o SourceGit.app/Contents/MacOS
1313
zip sourcegit_${version}.osx-arm64.zip -r SourceGit.app -x "*/*\.dsym/*"
1414

1515
rm -rf SourceGit.app/Contents/MacOS
1616

1717
mkdir -p SourceGit.app/Contents/MacOS
18-
dotnet publish ../src/SourceGit.csproj -c Release -r osx-x64 -o SourceGit.app/Contents/MacOS -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained
18+
dotnet publish ../src/SourceGit.csproj -c Release -r osx-x64 -o SourceGit.app/Contents/MacOS
1919
zip sourcegit_${version}.osx-x64.zip -r SourceGit.app -x "*/*\.dsym/*"
2020

2121
rm -rf SourceGit.app

build/build.windows.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ if (Test-Path SourceGit) {
66

77
Remove-Item *.zip -Force
88

9-
dotnet publish ..\src\SourceGit.csproj -c Release -r win-arm64 -o SourceGit -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained
9+
dotnet publish ..\src\SourceGit.csproj -c Release -r win-arm64 -o SourceGit
1010

1111
Remove-Item SourceGit\*.pdb -Force
1212

@@ -16,7 +16,7 @@ if (Test-Path SourceGit) {
1616
Remove-Item SourceGit -Recurse -Force
1717
}
1818

19-
dotnet publish ..\src\SourceGit.csproj -c Release -r win-x64 -o SourceGit -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained
19+
dotnet publish ..\src\SourceGit.csproj -c Release -r win-x64 -o SourceGit
2020

2121
Remove-Item SourceGit\*.pdb -Force
2222

build/resources/app/App.plist

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,30 @@
22
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
33
<plist version="1.0">
44
<dict>
5-
<key>CFBundleIconFile</key>
6-
<string>App.icns</string>
7-
<key>CFBundleIdentifier</key>
8-
<string>com.sourcegit-scm.sourcegit</string>
9-
<key>CFBundleName</key>
10-
<string>SourceGit</string>
11-
<key>CFBundleVersion</key>
12-
<string>SOURCE_GIT_VERSION.0</string>
13-
<key>LSMinimumSystemVersion</key>
14-
<string>10.12</string>
15-
<key>LSEnvironment</key>
16-
<dict>
17-
<key>PATH</key>
18-
<string>/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin</string>
19-
</dict>
20-
<key>CFBundleExecutable</key>
21-
<string>SourceGit</string>
22-
<key>CFBundleInfoDictionaryVersion</key>
23-
<string>6.0</string>
24-
<key>CFBundlePackageType</key>
25-
<string>APPL</string>
26-
<key>CFBundleShortVersionString</key>
27-
<string>SOURCE_GIT_VERSION</string>
28-
<key>NSHighResolutionCapable</key>
29-
<true/>
5+
<key>CFBundleIconFile</key>
6+
<string>App.icns</string>
7+
<key>CFBundleIdentifier</key>
8+
<string>com.sourcegit-scm.sourcegit</string>
9+
<key>CFBundleName</key>
10+
<string>SourceGit</string>
11+
<key>CFBundleVersion</key>
12+
<string>SOURCE_GIT_VERSION.0</string>
13+
<key>LSMinimumSystemVersion</key>
14+
<string>11.0</string>
15+
<key>LSEnvironment</key>
16+
<dict>
17+
<key>PATH</key>
18+
<string>/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin</string>
19+
</dict>
20+
<key>CFBundleExecutable</key>
21+
<string>SourceGit</string>
22+
<key>CFBundleInfoDictionaryVersion</key>
23+
<string>6.0</string>
24+
<key>CFBundlePackageType</key>
25+
<string>APPL</string>
26+
<key>CFBundleShortVersionString</key>
27+
<string>SOURCE_GIT_VERSION</string>
28+
<key>NSHighResolutionCapable</key>
29+
<true/>
3030
</dict>
3131
</plist>

build/resources/appimage/publish-appimage.conf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ DOTNET_PROJECT_PATH="../../../src/SourceGit.csproj"
8282
# Additional useful arguments include:
8383
# "-p:DebugType=None -p:DebugSymbols=false -p:PublishSingleFile=true -p:PublishTrimmed=true -p:TrimMode=link"
8484
# Refer: https://docs.microsoft.com/en-us/dotnet/core/tools/dotnet-publish
85-
DOTNET_PUBLISH_ARGS="-c Release -p:DebugType=None -p:DebugSymbols=false -p:PublishAot=true -p:PublishTrimmed=true -p:TrimMode=link --self-contained"
85+
DOTNET_PUBLISH_ARGS="-c Release -p:DebugType=None -p:DebugSymbols=false"
8686

8787

8888
########################################
@@ -137,4 +137,4 @@ PKG_APPIMAGE_SUFFIX=".AppImage"
137137
APPIMAGETOOL_COMMAND="appimagetool"
138138

139139
# Internal use only. Used for compatibility between conf and script. Do not modify.
140-
CONF_IMPL_VERSION=1
140+
CONF_IMPL_VERSION=1

src/App.JsonCodeGen.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ public override void Write(Utf8JsonWriter writer, GridLength value, JsonSerializ
6262
[JsonSerializable(typeof(Models.JetBrainsState))]
6363
[JsonSerializable(typeof(Models.ThemeOverrides))]
6464
[JsonSerializable(typeof(Models.Version))]
65+
[JsonSerializable(typeof(Models.RepositorySettings))]
6566
[JsonSerializable(typeof(ViewModels.Preference))]
66-
[JsonSerializable(typeof(ViewModels.RepositorySettings))]
6767
internal partial class JsonCodeGen : JsonSerializerContext { }
6868
}

src/App.axaml.cs

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ public static AppBuilder BuildAvaloniaApp()
9292
var toplevel = GetTopLevel() as Window;
9393
if (toplevel == null)
9494
return;
95-
95+
9696
var dialog = new Views.Preference();
9797
dialog.ShowDialog(toplevel);
9898
});
@@ -102,7 +102,7 @@ public static AppBuilder BuildAvaloniaApp()
102102
var toplevel = GetTopLevel() as Window;
103103
if (toplevel == null)
104104
return;
105-
105+
106106
var dialog = new Views.Hotkeys();
107107
dialog.ShowDialog(toplevel);
108108
});
@@ -112,7 +112,7 @@ public static AppBuilder BuildAvaloniaApp()
112112
var toplevel = GetTopLevel() as Window;
113113
if (toplevel == null)
114114
return;
115-
115+
116116
var dialog = new Views.About();
117117
dialog.ShowDialog(toplevel);
118118
});
@@ -247,7 +247,7 @@ public static Avalonia.Controls.Shapes.Path CreateMenuIcon(string key)
247247
var geo = Current?.FindResource(key) as StreamGeometry;
248248
if (geo != null)
249249
icon.Data = geo;
250-
250+
251251
return icon;
252252
}
253253

@@ -257,7 +257,7 @@ public static TopLevel GetTopLevel()
257257
{
258258
return desktop.MainWindow;
259259
}
260-
260+
261261
return null;
262262
}
263263

@@ -302,6 +302,11 @@ public static void Check4Update(bool manually = false)
302302
});
303303
}
304304

305+
public static ViewModels.Launcher GetLauncer()
306+
{
307+
return Current is App app ? app._launcher : null;
308+
}
309+
305310
public static ViewModels.Repository FindOpenedRepository(string repoPath)
306311
{
307312
if (Current is App app && app._launcher != null)
@@ -501,10 +506,15 @@ private bool TryLaunchedAsCoreEditor(IClassicDesktopStyleApplicationLifetime des
501506
private bool TryLaunchedAsAskpass(IClassicDesktopStyleApplicationLifetime desktop)
502507
{
503508
var args = desktop.Args;
504-
if (args == null || args.Length != 1 || !args[0].StartsWith("Enter passphrase", StringComparison.Ordinal))
509+
if (args == null || args.Length != 1)
510+
return false;
511+
512+
var param = args[0];
513+
if (!param.StartsWith("enter passphrase", StringComparison.OrdinalIgnoreCase) &&
514+
!param.Contains(" password", StringComparison.OrdinalIgnoreCase))
505515
return false;
506516

507-
desktop.MainWindow = new Views.Askpass(args[0]);
517+
desktop.MainWindow = new Views.Askpass(param);
508518
return true;
509519
}
510520

src/Commands/AssumeUnchanged.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ namespace SourceGit.Commands
55
{
66
public partial class AssumeUnchanged
77
{
8-
partial class ViewCommand : Command
9-
{
10-
[GeneratedRegex(@"^(\w)\s+(.+)$")]
11-
private static partial Regex REG();
8+
[GeneratedRegex(@"^(\w)\s+(.+)$")]
9+
private static partial Regex REG_PARSE();
1210

11+
class ViewCommand : Command
12+
{
1313
public ViewCommand(string repo)
1414
{
1515
WorkingDirectory = repo;
@@ -25,7 +25,7 @@ public List<string> Result()
2525

2626
protected override void OnReadline(string line)
2727
{
28-
var match = REG().Match(line);
28+
var match = REG_PARSE().Match(line);
2929
if (!match.Success)
3030
return;
3131

0 commit comments

Comments
 (0)