File tree Expand file tree Collapse file tree 3 files changed +39
-9
lines changed
Expand file tree Collapse file tree 3 files changed +39
-9
lines changed Original file line number Diff line number Diff line change 99 name : Release
1010 strategy :
1111 matrix :
12- kind : ['linux', 'windows', 'macOS']
12+ kind : ['linux', 'windows', 'macOS-x64', 'macOS-arm64 ']
1313 include :
1414 - kind : linux
1515 os : ubuntu-latest
1616 target : linux-x64
1717 - kind : windows
1818 os : windows-latest
1919 target : win-x64
20- - kind : macOS
20+ - kind : macOS-x64
2121 os : macos-latest
2222 target : osx-x64
23+ - kind : macOS-arm64
24+ os : macos-latest
25+ target : osx-arm64
2326 runs-on : ${{ matrix.os }}
2427
2528 steps :
4447 # Pack files
4548 if [ "${{ matrix.target }}" == "win-x64" ]; then
4649 7z a -tzip "${release_name}.zip" "./${release_name}/*"
47-
48- dotnet pack --configuration ReleaseLibrary --output .
49-
50- dotnet nuget push SqlInliner.$tag.nupkg --api-key $NUGET_TOKEN
5150 else
5251 tar czvf "${release_name}.tar.gz" "$release_name"
5352 fi
6160 files : " SqlInliner-*"
6261 env :
6362 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
64- NUGET_TOKEN : ${{ secrets.NUGET }}
Original file line number Diff line number Diff line change 1+ name : Publish to NuGet
2+
3+ on :
4+ push :
5+ tags :
6+ - ' [0-9]+.[0-9]+.[0-9]+'
7+
8+ jobs :
9+ publish :
10+ runs-on : ubuntu-latest
11+ permissions :
12+ id-token : write # Required for OIDC trusted publishing
13+ contents : read
14+
15+ steps :
16+ - uses : actions/checkout@v6
17+
18+ - name : Setup .NET
19+ uses : actions/setup-dotnet@v5
20+ with :
21+ dotnet-version : ' 8.0.x'
22+
23+ - name : Pack
24+ run : dotnet pack src/SqlInliner/SqlInliner.csproj -c Release --output ./nupkg
25+
26+ - name : NuGet login (OIDC)
27+ uses : nuget/login@v1
28+ id : login
29+ with :
30+ user : ${{ vars.NUGET_USER }}
31+
32+ - name : Publish to NuGet
33+ run : dotnet nuget push ./nupkg/*.nupkg --api-key ${{ steps.login.outputs.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json
Original file line number Diff line number Diff line change 2424 <PublishSingleFile >True</PublishSingleFile >
2525 <PublishReadyToRun >True</PublishReadyToRun >
2626 <PublishTrimmed >True</PublishTrimmed >
27- <TrimMode >Link</TrimMode >
2827 </PropertyGroup >
2928
3029 <PropertyGroup Condition =" '$(Configuration)' == 'ReleaseLibrary'" >
3130 <OutputType >Library</OutputType >
32- <TargetFrameworks >net472;netstandard2.0;netcoreapp3.1;net6 .0;net8 .0</TargetFrameworks >
31+ <TargetFrameworks >net472;netstandard2.0;net8.0;net9 .0;net10 .0</TargetFrameworks >
3332 <GenerateDocumentationFile >true</GenerateDocumentationFile >
3433 </PropertyGroup >
3534
You can’t perform that action at this time.
0 commit comments