From 0458fc623771c21b63d98277ff243770c498dced Mon Sep 17 00:00:00 2001 From: Dom Slee Date: Wed, 10 Jun 2026 18:24:18 +1000 Subject: [PATCH 1/5] Package the dotnet tool as RID-specific Native AOT (win-x64) Uses .NET SDK 10 RID-specific tool packaging so `dotnet tool install forceops` installs the Native AOT binary on x64 Windows, with a framework-dependent `any` fallback for other platforms. Removes the UseAot conditional build and the separate AOT publish step. Co-Authored-By: Claude Fable 5 --- .github/workflows/release.yaml | 18 +++++++----------- ForceOps/ForceOps.csproj | 13 +++++++++---- README.md | 2 ++ 3 files changed, 18 insertions(+), 15 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index de134dc..22d54e8 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -44,15 +44,8 @@ jobs: - name: Pack run: | dotnet pack -c release /p:ContinuousIntegrationBuild=true - cp -r ForceOps/nupkg ForceOps/nupkg_pack - cp -r ForceOps.Lib/nupkg ForceOps.Lib/nupkg_pack - dotnet clean - - - name: Build (AOT) - run: | - dotnet publish -c release /p:UseAot=1 /p:ContinuousIntegrationBuild=true - cp -r ForceOps/bin ForceOps/bin_aot - dotnet clean + dotnet pack ForceOps -c release -r win-x64 /p:ContinuousIntegrationBuild=true + dotnet pack ForceOps -c release -r any -p:PublishAot=false /p:ContinuousIntegrationBuild=true - name: Create release if: ${{ github.ref == 'refs/heads/main' && startsWith(github.event.head_commit.message, 'chore(release)') }} @@ -60,10 +53,13 @@ jobs: with: draft: true name: "${{ steps.get_version.outputs.version }}" - files: ForceOps/bin_aot/Release/net10.0/win-x64/publish/ForceOps.exe + files: ForceOps/bin/release/net10.0/win-x64/publish/ForceOps.exe tag_name: "${{ steps.get_version.outputs.version }}" + # RID-specific packages must be on the feed before the top-level pointer + # package, so the pointer package is pushed in a second step. - name: Publish NuGet if: ${{ github.ref == 'refs/heads/main' && startsWith(github.event.head_commit.message, 'chore(release)') }} run: | - dotnet nuget push -k ${{ secrets.NUGET_AUTH_TOKEN }} -s https://api.nuget.org/v3/index.json ForceOps/nupkg_pack/ForceOps.${{ steps.get_version.outputs.version }}.nupkg ForceOps.Lib/nupkg_pack/ForceOps.Lib.${{ steps.get_version.outputs.version }}.nupkg ForceOps.Lib/nupkg_pack/ForceOps.Lib.${{ steps.get_version.outputs.version }}.snupkg --skip-duplicate + dotnet nuget push -k ${{ secrets.NUGET_AUTH_TOKEN }} -s https://api.nuget.org/v3/index.json ForceOps/nupkg/ForceOps.win-x64.${{ steps.get_version.outputs.version }}.nupkg ForceOps/nupkg/ForceOps.any.${{ steps.get_version.outputs.version }}.nupkg ForceOps.Lib/nupkg/ForceOps.Lib.${{ steps.get_version.outputs.version }}.nupkg ForceOps.Lib/nupkg/ForceOps.Lib.${{ steps.get_version.outputs.version }}.snupkg --skip-duplicate + dotnet nuget push -k ${{ secrets.NUGET_AUTH_TOKEN }} -s https://api.nuget.org/v3/index.json ForceOps/nupkg/ForceOps.${{ steps.get_version.outputs.version }}.nupkg --skip-duplicate diff --git a/ForceOps/ForceOps.csproj b/ForceOps/ForceOps.csproj index 7eced39..8a8cea4 100644 --- a/ForceOps/ForceOps.csproj +++ b/ForceOps/ForceOps.csproj @@ -9,14 +9,19 @@ ./nupkg - + true forceops - - + true - win-x64 + win-x64;any diff --git a/README.md b/README.md index e8c8cb9..e51fab9 100644 --- a/README.md +++ b/README.md @@ -29,6 +29,8 @@ scoop update forceops --force dotnet tool install -g forceops ``` +On x64 Windows this installs the [Native AOT](https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/) build (same fast startup as the scoop install). Other architectures get a framework-dependent build. Requires the .NET 10 SDK or later to install. + To update: ```shell dotnet tool update -g forceops From 78d9ae98c03171fd744be5fd0f18aace0b242007 Mon Sep 17 00:00:00 2001 From: Dom Slee Date: Wed, 10 Jun 2026 20:31:21 +1000 Subject: [PATCH 2/5] Modernize AOT benchmark comment to NativeAot10_0 Co-Authored-By: Claude Fable 5 --- ForceOps.Benchmarks/src/FileAndDirectoryDeleterBenchmark.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ForceOps.Benchmarks/src/FileAndDirectoryDeleterBenchmark.cs b/ForceOps.Benchmarks/src/FileAndDirectoryDeleterBenchmark.cs index 32c8538..33d2462 100644 --- a/ForceOps.Benchmarks/src/FileAndDirectoryDeleterBenchmark.cs +++ b/ForceOps.Benchmarks/src/FileAndDirectoryDeleterBenchmark.cs @@ -3,7 +3,7 @@ namespace ForceOps.Benchmarks; -// [SimpleJob(RuntimeMoniker.NativeAot80)] +// [SimpleJob(RuntimeMoniker.NativeAot10_0)] [SimpleJob] public class FileAndDirectoryDeleterBenchmark { From 6e8c905e74d29db0cbf09436e597c45c1b3c844b Mon Sep 17 00:00:00 2001 From: Dom Slee Date: Wed, 10 Jun 2026 20:47:40 +1000 Subject: [PATCH 3/5] Switch scoop install to the domsleee/scoop-bucket; publish sha256 sidecar The bucket has checkver/autoupdate so manifests update automatically from releases; the .sha256 release asset feeds the autoupdate hash. Co-Authored-By: Claude Fable 5 --- .github/workflows/release.yaml | 11 ++++++++++- README.md | 5 +++-- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 22d54e8..a8cbf0e 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -47,13 +47,22 @@ jobs: dotnet pack ForceOps -c release -r win-x64 /p:ContinuousIntegrationBuild=true dotnet pack ForceOps -c release -r any -p:PublishAot=false /p:ContinuousIntegrationBuild=true + # The .sha256 sidecar is used by the scoop bucket's autoupdate + # (https://github.com/domsleee/scoop-bucket). + - name: Create sha256 for release exe + run: | + $exe = "ForceOps/bin/release/net10.0/win-x64/publish/ForceOps.exe" + (Get-FileHash $exe -Algorithm SHA256).Hash.ToLower() | Set-Content -NoNewline "$exe.sha256" + - name: Create release if: ${{ github.ref == 'refs/heads/main' && startsWith(github.event.head_commit.message, 'chore(release)') }} uses: softprops/action-gh-release@v2 with: draft: true name: "${{ steps.get_version.outputs.version }}" - files: ForceOps/bin/release/net10.0/win-x64/publish/ForceOps.exe + files: | + ForceOps/bin/release/net10.0/win-x64/publish/ForceOps.exe + ForceOps/bin/release/net10.0/win-x64/publish/ForceOps.exe.sha256 tag_name: "${{ steps.get_version.outputs.version }}" # RID-specific packages must be on the feed before the top-level pointer diff --git a/README.md b/README.md index e51fab9..b05146a 100644 --- a/README.md +++ b/README.md @@ -15,12 +15,13 @@ Uses [LockChecker](https://github.com/domsleee/LockCheck) to find processes lock It has a faster startup because it uses [Native AOT](https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/): ```shell -scoop install https://gist.github.com/domsleee/f765105f512ec607ee0a6e3ee5debd6d/raw/forceops.json +scoop bucket add domsleee https://github.com/domsleee/scoop-bucket +scoop install forceops ``` To update: ```shell -scoop update forceops --force +scoop update forceops ``` ### Alternative - install with [`dotnet`](https://dotnet.microsoft.com/en-us/download) From f03c8d50ba43f1a0f8e4d8fd588b01b71499a209 Mon Sep 17 00:00:00 2001 From: Dom Slee Date: Wed, 10 Jun 2026 21:20:10 +1000 Subject: [PATCH 4/5] README: both scoop and dotnet tool installs are Native AOT now Co-Authored-By: Claude Fable 5 --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index b05146a..3a62ae3 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ Uses [LockChecker](https://github.com/domsleee/LockCheck) to find processes lock ## Installation ### Install with [`scoop`](http://scoop.sh/) (recommended) -It has a faster startup because it uses [Native AOT](https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/): +Installs the [Native AOT](https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/) build and doesn't require the .NET SDK: ```shell scoop bucket add domsleee https://github.com/domsleee/scoop-bucket @@ -30,7 +30,7 @@ scoop update forceops dotnet tool install -g forceops ``` -On x64 Windows this installs the [Native AOT](https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/) build (same fast startup as the scoop install). Other architectures get a framework-dependent build. Requires the .NET 10 SDK or later to install. +On x64 Windows this installs the same Native AOT build as the scoop install. Other architectures get a framework-dependent build. Requires the .NET 10 SDK or later to install. To update: ```shell From 2278aa8b231023741e22692ca0a26f5f1ec2ffe1 Mon Sep 17 00:00:00 2001 From: Dom Slee Date: Wed, 10 Jun 2026 21:20:59 +1000 Subject: [PATCH 5/5] Trim RID packaging comment to a doc link Co-Authored-By: Claude Fable 5 --- ForceOps/ForceOps.csproj | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/ForceOps/ForceOps.csproj b/ForceOps/ForceOps.csproj index 8a8cea4..e54f313 100644 --- a/ForceOps/ForceOps.csproj +++ b/ForceOps/ForceOps.csproj @@ -13,13 +13,7 @@ true forceops - + true win-x64;any