Skip to content

Commit

Permalink
Update to .NET 9 (#196)
Browse files Browse the repository at this point in the history
* Update to .NET 9

* does that make you happy?

* make a note to update the github action

---------

Co-authored-by: ike709 <[email protected]>
  • Loading branch information
ike709 and ike709 authored Dec 7, 2024
1 parent 7fb248c commit ed386b8
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0.x
dotnet-version: 9.0.x
- name: Install dependencies
run: dotnet restore
- name: Build
Expand Down
3 changes: 2 additions & 1 deletion Launcher.props
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@
1. Packaging scripts.
2. Download .NET runtime script.
3. Local dev SS14.Loader launching code.
4. build-test.yml GitHub Actions workflow
-->
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
<Version>0.29.1</Version>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion SS14.Launcher/Models/Connector.cs
Original file line number Diff line number Diff line change
Expand Up @@ -597,7 +597,7 @@ private static async Task<ProcessStartInfo> GetLoaderStartInfo()
basePath = Path.GetFullPath(Path.Combine(
LauncherPaths.DirLauncherInstall,
"..", "..", "..", "..",
"SS14.Loader", "bin", "Debug", "net8.0"));
"SS14.Loader", "bin", "Debug", "net9.0"));
}

if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux) || RuntimeInformation.IsOSPlatform(OSPlatform.FreeBSD))
Expand Down
8 changes: 4 additions & 4 deletions download_net_runtime.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@
PLATFORM_LINUX = "linux"
PLATFORM_MACOS = "mac"

DOTNET_RUNTIME_VERSION = "8.0.0"
DOTNET_RUNTIME_VERSION = "9.0.0"

DOTNET_RUNTIME_DOWNLOADS = {
PLATFORM_LINUX: "https://download.visualstudio.microsoft.com/download/pr/fc4b4447-45f2-4fd2-899a-77eb1aed7792/6fd52c0c61f064ddc7fe7684e841f491/dotnet-runtime-8.0.0-linux-x64.tar.gz",
PLATFORM_WINDOWS: "https://download.visualstudio.microsoft.com/download/pr/924f2e25-ba50-4b90-a35c-6ef73d1149a3/b9a57fa45dad7cca93a0aa937a8ba03d/dotnet-runtime-8.0.0-win-x64.zip",
PLATFORM_MACOS: "https://download.visualstudio.microsoft.com/download/pr/65e0ad28-b73d-46ab-b3ae-2d2ae4460b78/50ee103e816a255f9a5331bc2975a6ef/dotnet-runtime-8.0.0-osx-x64.tar.gz"
PLATFORM_LINUX: "https://download.visualstudio.microsoft.com/download/pr/282bb881-c2ae-4250-b814-b362745073bd/6e15021d23f704c0d457c820a69a3de6/dotnet-runtime-9.0.0-linux-x64.tar.gz",
PLATFORM_WINDOWS: "https://download.visualstudio.microsoft.com/download/pr/fed1ee33-4574-4d89-85b5-3b8d7762b56a/432725cb9d6d235424768defea5ce6ee/dotnet-runtime-9.0.0-win-x64.zip",
PLATFORM_MACOS: "https://download.visualstudio.microsoft.com/download/pr/4be484a1-a095-48cf-8407-cae1d3dcc944/9f373dc1d85022e004df3ac1071ace59/dotnet-runtime-9.0.0-osx-x64.tar.gz"
}

p = os.path.join
Expand Down
4 changes: 2 additions & 2 deletions publish_linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ mkdir -p bin/publish/Linux/bin/loader
mkdir -p bin/publish/Linux/dotnet

cp PublishFiles/SS14.Launcher PublishFiles/SS14.desktop bin/publish/Linux/
cp SS14.Launcher/bin/Release/net8.0/linux-x64/publish/* bin/publish/Linux/bin/
cp SS14.Loader/bin/Release/net8.0/linux-x64/publish/* bin/publish/Linux/bin/loader
cp SS14.Launcher/bin/Release/net9.0/linux-x64/publish/* bin/publish/Linux/bin/
cp SS14.Loader/bin/Release/net9.0/linux-x64/publish/* bin/publish/Linux/bin/loader
cp -r Dependencies/dotnet/linux/* bin/publish/Linux/dotnet/

cd bin/publish/Linux
Expand Down
4 changes: 2 additions & 2 deletions publish_osx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ mkdir -p "bin/publish/macOS/Space Station 14 Launcher.app/Contents/Resources/bin
mkdir -p "bin/publish/macOS/Space Station 14 Launcher.app/Contents/Resources/bin/loader/Space Station 14.app/Contents/Resources/bin/"

cp -r Dependencies/dotnet/mac/* "bin/publish/macOS/Space Station 14 Launcher.app/Contents/Resources/dotnet/"
cp -r SS14.Launcher/bin/Release/net8.0/osx-x64/publish/* "bin/publish/macOS/Space Station 14 Launcher.app/Contents/Resources/bin/"
cp -r SS14.Loader/bin/Release/net8.0/osx-x64/publish/* "bin/publish/macOS/Space Station 14 Launcher.app/Contents/Resources/bin/loader/Space Station 14.app/Contents/Resources/bin/"
cp -r SS14.Launcher/bin/Release/net9.0/osx-x64/publish/* "bin/publish/macOS/Space Station 14 Launcher.app/Contents/Resources/bin/"
cp -r SS14.Loader/bin/Release/net9.0/osx-x64/publish/* "bin/publish/macOS/Space Station 14 Launcher.app/Contents/Resources/bin/loader/Space Station 14.app/Contents/Resources/bin/"
pushd bin/publish/macOS
zip -r ../../../SS14.Launcher_macOS.zip *
popd
8 changes: 4 additions & 4 deletions publish_windows.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ dotnet publish SS14.Launcher/SS14.Launcher.csproj /p:FullRelease=True -c Release
dotnet publish SS14.Loader/SS14.Loader.csproj -c Release --no-self-contained -r win-x64 /nologo
dotnet publish SS14.Launcher.Bootstrap/SS14.Launcher.Bootstrap.csproj -c Release /nologo

./exe_set_subsystem.py "SS14.Launcher/bin/Release/net8.0/win-x64/publish/SS14.Launcher.exe" 2
./exe_set_subsystem.py "SS14.Loader/bin/Release/net8.0/win-x64/publish/SS14.Loader.exe" 2
./exe_set_subsystem.py "SS14.Launcher/bin/Release/net9.0/win-x64/publish/SS14.Launcher.exe" 2
./exe_set_subsystem.py "SS14.Loader/bin/Release/net9.0/win-x64/publish/SS14.Loader.exe" 2

# Create intermediate directories.
mkdir -p bin/publish/Windows/bin
Expand All @@ -23,8 +23,8 @@ mkdir -p bin/publish/Windows/dotnet
cp -r Dependencies/dotnet/windows/* bin/publish/Windows/dotnet
cp "SS14.Launcher.Bootstrap/bin/Release/net45/publish/Space Station 14 Launcher.exe" bin/publish/Windows
cp "SS14.Launcher.Bootstrap/console.bat" bin/publish/Windows
cp SS14.Launcher/bin/Release/net8.0/win-x64/publish/* bin/publish/Windows/bin
cp SS14.Loader/bin/Release/net8.0/win-x64/publish/* bin/publish/Windows/bin/loader
cp SS14.Launcher/bin/Release/net9.0/win-x64/publish/* bin/publish/Windows/bin
cp SS14.Loader/bin/Release/net9.0/win-x64/publish/* bin/publish/Windows/bin/loader

pushd bin/publish/Windows
zip -r ../../../SS14.Launcher_Windows.zip *
Expand Down

0 comments on commit ed386b8

Please sign in to comment.