Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,15 @@ container (`ghcr.io/nullean/release-notes`) and a GitHub Action (`action.yml`) t

| Path | What |
|---|---|
| `src/release-notes` | the tool (net8.0 and net10.0), a `Nullean.Argh` CLI; `ReleaseNotesCommands.cs` holds the commands |
| `src/release-notes` | the tool (net10.0 and net11.0), a `Nullean.Argh` CLI; `ReleaseNotesCommands.cs` holds the commands |
| `src/release-notes/GitHubReleaseClient.cs` | the GitHub writes (releases, labels), source-generated JSON instead of Octokit |
| `build/scripts` | the F# build ([Nullean.Make.Fs](https://www.nuget.org/packages/Nullean.Make.Fs), net11.0) the `mise` tasks and CI call |
| `build/keys` | the strong-name key the tool's own assembly is signed with |
| `action.yml` | the GitHub Action: runs the `edge` container image |

## Commands

mise installs the SDK pinned in `global.json` (plus the net10.0 runtime nupkg-validator runs on). Run
everything through it:
mise installs the SDK pinned in `global.json`. Run everything through it:

```bash
mise run build # build the solution
Expand Down
8 changes: 3 additions & 5 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,8 @@
<!-- the tool -->
<ItemGroup>
<PackageVersion Include="MinVer" Version="8.0.0" />
<PackageVersion Include="Nullean.Argh" Version="0.28.0" />
<!-- NuGet.Versioning 8 targets only net10.0 and net472: net8.0 would fall back to the .NET Framework build (NU1701) -->
<PackageVersion Include="NuGet.Versioning" Version="8.0.0" Condition="'$(TargetFramework)' != 'net8.0'" />
<PackageVersion Include="NuGet.Versioning" Version="7.9.0" Condition="'$(TargetFramework)' == 'net8.0'" />
<PackageVersion Include="Nullean.Argh" Version="0.30.0" />
<PackageVersion Include="NuGet.Versioning" Version="8.0.0" />
<PackageVersion Include="Octokit" Version="14.0.0" />
</ItemGroup>

Expand All @@ -18,6 +16,6 @@
<!-- under CPM the F# SDK adds no implicit FSharp.Core; Nullean.Make.Fs needs 11.0.100 or later -->
<PackageVersion Include="FSharp.Core" Version="11.0.101" />
<!-- brings Proc and Proc.Fs -->
<PackageVersion Include="Nullean.Make.Fs" Version="0.28.0" />
<PackageVersion Include="Nullean.Make.Fs" Version="0.30.0" />
</ItemGroup>
</Project>
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ The tool ships as one package per platform. Install the root package; the .NET S
|---|---|---|
| [`release-notes`](src/release-notes/README.md) | the tool; points the SDK at the package for your platform | [![NuGet](https://img.shields.io/nuget/v/release-notes?style=flat-square)](https://www.nuget.org/packages/release-notes) |
| `release-notes.<rid>` | the native-AOT build for `linux-x64`, `linux-arm64`, `win-x64`, `win-arm64` and `osx-arm64` | [![NuGet](https://img.shields.io/nuget/v/release-notes.linux-x64?style=flat-square)](https://www.nuget.org/packages/release-notes.linux-x64) |
| `release-notes.any` | the framework-dependent fallback (net8.0, net10.0) for every other platform | [![NuGet](https://img.shields.io/nuget/v/release-notes.any?style=flat-square)](https://www.nuget.org/packages/release-notes.any) |
| `release-notes.any` | the framework-dependent fallback (net10.0, net11.0) for every other platform | [![NuGet](https://img.shields.io/nuget/v/release-notes.any?style=flat-square)](https://www.nuget.org/packages/release-notes.any) |

## Learn more

Expand Down
2 changes: 1 addition & 1 deletion build/scripts/Paths.fs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ let AotRuntimeIdentifiers = ["linux-x64"; "linux-arm64"; "win-x64"; "win-arm64";

/// Must mirror release-notes.csproj's TargetFrameworks. Used to patch the signed managed dll back
/// into the packed 'any' fallback for every TFM it ships — see fixAnyPackageSigning in Targets.fs.
let ManagedTargetFrameworks = ["net8.0"; "net10.0"]
let ManagedTargetFrameworks = ["net10.0"; "net11.0"]

let Root =
let mutable dir = DirectoryInfo(".")
Expand Down
12 changes: 6 additions & 6 deletions build/scripts/Program.fs
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ let main argv =
for project in Directory.EnumerateFiles("src", "*.?sproj", SearchOption.AllDirectories) do
sh $"dotnet clean {project} -c Release -v q" }
| Build -> command {
composes [Clean]
executes (shell { sh $"dotnet build -c Release" }) }
composes [Clean] }
|> executes { sh $"dotnet build -c Release" }
// there are no tests, so ci is pack: build, then create, validate and diff the packages
| Pack -> command { requires [Build]; composes [Generatepackages; Validatepackages; Generateapichanges] }
| Ci -> command { requires [Pack]; composes [] }
Expand Down Expand Up @@ -107,13 +107,13 @@ let main argv =
// works, with no ghcr.io credentials configured there. Only the build job, which does log in, passes
// --push.
| Publishcontainers -> target [] {
let baseImage = "mcr.microsoft.com/dotnet/runtime-deps:10.0-noble-chiseled"
let baseImage = "mcr.microsoft.com/dotnet/runtime-deps:11.0-resolute-chiseled"
// MSBuild reads the quotes: without them the tags' `;` would split the property
let tags = $"ContainerImageTags=\"{Packaging.containerImageTags Versions.current.Value}\""
if push.Value then
sh $"dotnet publish {toolProject} -c Release -f net10.0 -r linux-x64 /t:PublishContainer -p DebugType=none -p ContainerBaseImage={baseImage} -p ContainerRepository={Paths.Repository} -p {tags} -p ContainerUser=1001:1001 -p ContainerRegistry=ghcr.io"
sh $"dotnet publish {toolProject} -c Release -f net11.0 -r linux-x64 /t:PublishContainer -p DebugType=none -p ContainerBaseImage={baseImage} -p ContainerRepository={Paths.Repository} -p {tags} -p ContainerUser=1001:1001 -p ContainerRegistry=ghcr.io"
else
sh $"dotnet publish {toolProject} -c Release -f net10.0 -r linux-x64 /t:PublishContainer -p DebugType=none -p ContainerBaseImage={baseImage} -p ContainerRepository={Paths.Repository} -p {tags} -p ContainerUser=1001:1001" }
sh $"dotnet publish {toolProject} -c Release -f net11.0 -r linux-x64 /t:PublishContainer -p DebugType=none -p ContainerBaseImage={baseImage} -p ContainerRepository={Paths.Repository} -p {tags} -p ContainerUser=1001:1001" }

// The framework-dependent build cannot catch what trimming breaks: #47 broke only the native-AOT binary, where
// Octokit's reflection-based JSON returned nothing or threw. So this publishes that binary and reads releases
Expand All @@ -124,7 +124,7 @@ let main argv =
let rid = RuntimeInformation.RuntimeIdentifier
let publishDirectory = Path.Combine(Paths.Output.FullName, "aot-smoke")
let publish = Paths.RootRelative publishDirectory
sh $"dotnet publish {toolProject} -c Release -f net10.0 -r {rid} -o {publish}"
sh $"dotnet publish {toolProject} -c Release -f net11.0 -r {rid} -o {publish}"
let executable = if OperatingSystem.IsWindows() then $"{Paths.ToolName}.exe" else Paths.ToolName
let binary = Paths.RootRelative <| Path.Combine(publishDirectory, executable)
// Make.Fs quotes each interpolated hole as one argument, so --token stays in the command text
Expand Down
4 changes: 2 additions & 2 deletions mise.toml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# Bootstraps the toolchain and is the one entry point: `mise run <task>`, the same task names in every nullean repo.
# The .NET SDK version lives only in global.json: the first dotnet entry reads it from there (sdk.version is the first
# "version" key). The net10.0 runtime is listed after it because nupkg-validator runs on net10.0.
# "version" key). List further runtimes after it when tests run on older target frameworks too.

[env]
DOTNET_NOLOGO = "1"
DOTNET_CLI_TELEMETRY_OPTOUT = "1"
DOTNET_SKIP_FIRST_TIME_EXPERIENCE = "1"

[tools]
dotnet = ["""{{ read_file(path='global.json') | split(pat='"version"') | nth(n=1) | split(pat='"') | nth(n=1) }}""", "10"]
dotnet = ["""{{ read_file(path='global.json') | split(pat='"version"') | nth(n=1) | split(pat='"') | nth(n=1) }}"""]
gh = "latest"
zizmor = "1"

Expand Down
4 changes: 2 additions & 2 deletions src/release-notes/release-notes.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFrameworks>net8.0;net10.0</TargetFrameworks>
<TargetFrameworks>net10.0;net11.0</TargetFrameworks>
<AssemblyName>release-notes</AssemblyName>
<RootNamespace>ReleaseNotes</RootNamespace>
<ImplicitUsings>enable</ImplicitUsings>
Expand All @@ -22,7 +22,7 @@
The root package's DotnetToolSettings.xml (v2) maps each RID to its per-RID package.
Installing requires the .NET 10 SDK or greater. -->
<RuntimeIdentifiers>linux-x64;linux-arm64;win-x64;win-arm64;osx-arm64;any</RuntimeIdentifiers>
<!-- Lets `dotnet publish -f net10.0 -r <rid> -t:PublishContainer` containerize this same AOT
<!-- Lets `dotnet publish -f net11.0 -r <rid> -t:PublishContainer` containerize this same AOT
publish output — see build/scripts/Targets.fs's publishContainers target and
ghcr.io/nullean/release-notes. -->
<EnableSdkContainerSupport>true</EnableSdkContainerSupport>
Expand Down
Loading