Skip to content

Commit 4c15be4

Browse files
Merge pull request #168 from MattEqualsCoder/ui-rewrite
UI rewrite
2 parents 2eca5f6 + 48b1ee3 commit 4c15be4

File tree

213 files changed

+16799
-8673
lines changed

Some content is hidden

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

213 files changed

+16799
-8673
lines changed

.github/workflows/build.yml

Lines changed: 125 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,125 @@
1+
name: .NET Build + Publish
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
build-windows:
11+
runs-on: windows-2022
12+
13+
permissions:
14+
contents: write
15+
16+
outputs:
17+
version-number: ${{ steps.version.outputs.number}}
18+
19+
steps:
20+
- uses: actions/checkout@v4
21+
- name: Setup .NET
22+
uses: actions/setup-dotnet@v4
23+
with:
24+
dotnet-version: 9.0.x
25+
- name: Restore dependencies
26+
run: dotnet restore
27+
- name: Build
28+
run: dotnet build --no-restore -p:PostBuildEvent=
29+
- name: Publish Windows 64bit
30+
if: ${{ github.event_name != 'pull_request' }}
31+
run: dotnet publish --os win --arch x64 -c Release --self-contained false MSUScripter/MSUScripter.csproj
32+
- name: Publish Windows 32bit
33+
if: ${{ github.event_name != 'pull_request' }}
34+
run: dotnet publish --os win --arch x86 -c Release --self-contained false MSUScripter/MSUScripter.csproj
35+
- name: Get version number
36+
if: ${{ github.event_name != 'pull_request' }}
37+
id: version
38+
run: |
39+
$version = (Get-Item "MSUScripter\bin\Release\net9.0\win-x86\publish\MSUScripter.exe").VersionInfo.ProductVersion
40+
$version = $version.Split("+")[0]
41+
Write-Host $version
42+
Write-Output "number=$version" >> $env:GITHUB_OUTPUT
43+
shell: pwsh
44+
- name: Building the Windows installer
45+
if: ${{ github.event_name != 'pull_request' }}
46+
run: '"%programfiles(x86)%/Inno Setup 6/iscc.exe" "Setup/MSUScripter.iss"'
47+
shell: cmd
48+
- name: Upload artifact
49+
uses: actions/upload-artifact@v4
50+
if: ${{ github.event_name != 'pull_request' }}
51+
with:
52+
path: "setup/Output/*"
53+
name: MSUScripterWindows
54+
55+
build-linux:
56+
runs-on: ubuntu-22.04
57+
if: ${{ github.event_name != 'pull_request' }}
58+
needs: [build-windows]
59+
60+
permissions:
61+
contents: write
62+
63+
steps:
64+
- uses: actions/checkout@v4
65+
- name: Setup .NET
66+
uses: actions/setup-dotnet@v4
67+
with:
68+
dotnet-version: 9.0.x
69+
- name: Update VersionOverride in source file
70+
run: |
71+
pwd
72+
VERSION="${{ needs.build-windows.outputs.version-number }}"
73+
BASE_VERSION="${VERSION%%-*}"
74+
FILE="MSUScripter/App.axaml.cs"
75+
sed -i -E "s|^[[:space:]]*private static readonly string\?[[:space:]]+VersionOverride[[:space:]]*=[[:space:]]*null;|private static readonly string? VersionOverride = \"${VERSION}\";|" "$FILE"
76+
sed -i "s/^AppVersionRelease *= *.*/AppVersionRelease = ${BASE_VERSION}/" Setup/AppImage.pupnet.conf
77+
echo "Updated VersionOverride to: ${VERSION}"
78+
- name: Install PupNet
79+
run: dotnet tool install -g KuiperZone.PupNet
80+
- name: Download AppImageTool
81+
run: |
82+
wget -P "$HOME/.local/bin" "https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-x86_64.AppImage"
83+
chmod +x "$HOME/.local/bin/appimagetool-x86_64.AppImage"
84+
appimagetool-x86_64.AppImage --version
85+
- name: Run PupNet
86+
run: pupnet Setup/AppImage.pupnet.conf --kind appimage -y
87+
- name: Upload artifact
88+
uses: actions/upload-artifact@v4
89+
if: ${{ github.event_name != 'pull_request' }}
90+
with:
91+
path: "Setup/Output/MSUScripter*"
92+
name: MSUScripterLinux
93+
94+
package:
95+
runs-on: ubuntu-22.04
96+
needs: [build-windows, build-linux]
97+
if: ${{ github.event_name != 'pull_request' }}
98+
99+
permissions:
100+
contents: write
101+
102+
steps:
103+
- uses: actions/download-artifact@v5
104+
with:
105+
name: MSUScripterWindows
106+
path: out
107+
- uses: actions/download-artifact@v5
108+
with:
109+
name: MSUScripterLinux
110+
path: out
111+
- name: Extract some files
112+
run: |
113+
ls -alR
114+
- name: Upload artifact
115+
uses: actions/upload-artifact@v4
116+
if: ${{ github.event_name != 'pull_request' }}
117+
with:
118+
path: "out/*"
119+
name: MSUScripter_${{ needs.build-windows.outputs.version-number }}
120+
- name: Delete old artifacts
121+
uses: geekyeggo/delete-artifact@v5
122+
with:
123+
name: |
124+
MSUScripterWindows
125+
MSUScripterLinux

.github/workflows/dotnet.yml

Lines changed: 0 additions & 58 deletions
This file was deleted.

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ bld/
3131
[Oo]bj/
3232
[Ll]og/
3333
[Ll]ogs/
34+
[Dd]eploy/
3435

3536
# Visual Studio 2015/2017 cache/options directory
3637
.vs/
@@ -396,5 +397,6 @@ FodyWeavers.xsd
396397

397398
# JetBrains Rider
398399
*.sln.iml
400+
.idea/**/workspace.xml
399401

400-
Setup/output/*
402+
[Ss]etup/[Oo]utput/*

.idea/.idea.MSUScripter/.idea/.gitignore

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/.idea.MSUScripter/.idea/avalonia.xml

Lines changed: 12 additions & 39 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/.idea.MSUScripter/.idea/projectSettingsUpdater.xml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/.idea.MSUScripter/.idea/riderPublish.xml

Lines changed: 0 additions & 11 deletions
This file was deleted.

0 commit comments

Comments
 (0)