File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- name : Build Release (Linux x64)
1+ name : 🐧 Build Release (Linux x64)
22
33on :
44 workflow_call :
Original file line number Diff line number Diff line change 1+ name : 🍏 Build Release (MacOS arm64)
2+
3+ on :
4+ workflow_call :
5+ inputs :
6+ version :
7+ description : |
8+ The version to release. (eg: 0.1.2, exclude the 'v'.).
9+ required : true
10+ type : string
11+
12+ jobs :
13+ build-macos64 :
14+ runs-on : macos-14 # note this is arm64
15+
16+ steps :
17+ - uses : actions/checkout@v3
18+ - name : Setup .NET
19+ uses : actions/setup-dotnet@v3
20+ with :
21+ dotnet-version : 6.0.x
22+ - name : Restore dependencies
23+ run : dotnet restore
24+ - name : Build
25+ run : dotnet build -c Release --no-restore
26+
27+ - name : Build Bundle (MacOS)
28+ shell : bash
29+ run : |
30+ echo "Current Directory $(pwd)"
31+ # build the project
32+ dotnet publish ./src/CodeQLToolkit.Core/CodeQLToolkit.Core.csproj /p:PublishProfile=./src/CodeQLToolkit.Core/Properties/PublishProfiles/MacOS-arm64-Profile.pubxml
33+ cp ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/macos-arm64/CodeQLToolkit.Core ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/macos-arm64/qlt
34+
35+ # repair permissions
36+ chmod +x ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/macos-arm64/qlt
37+ chmod +r -R ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/macos-arm64
38+
39+ # create bundle
40+ ARCHIVE="$(pwd)/qlt-macos-arm64.zip"
41+ pushd ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/macos-arm64
42+ zip -r $ARCHIVE .
43+ popd
44+
45+ - name : Upload build artifacts
46+ uses : actions/upload-artifact@v3
47+ with :
48+ name : qlt-dist
49+ path : qlt*.zip
50+
51+ - name : Upload Build Artifacts
52+ shell : pwsh
53+ run : |
54+ Write-Host (Get-Location)
55+ gh release upload v${{inputs.version}} ./qlt-macos-arm64.zip
56+ env :
57+ GH_TOKEN : ${{ github.token }}
Original file line number Diff line number Diff line change 1+ name : 🪟 Build Release (Windows x64)
2+
3+ on :
4+ workflow_call :
5+ inputs :
6+ version :
7+ description : |
8+ The version to release. (eg: 0.1.2, exclude the 'v'.).
9+ required : true
10+ type : string
11+
12+ jobs :
13+ build-win64 :
14+ runs-on : windows-latest
15+
16+ steps :
17+ - uses : actions/checkout@v3
18+ - name : Setup .NET
19+ uses : actions/setup-dotnet@v3
20+ with :
21+ dotnet-version : 6.0.x
22+ - name : Restore dependencies
23+ run : dotnet restore
24+ - name : Build
25+ run : dotnet build -c Release --no-restore
26+
27+ - name : Build Bundle (MacOS)
28+ shell : bash
29+ run : |
30+ echo "Current Directory $(pwd)"
31+ # build the project
32+ dotnet publish ./src/CodeQLToolkit.Core/CodeQLToolkit.Core.csproj /p:PublishProfile=./src/CodeQLToolkit.Core/Properties/PublishProfiles/Windows-x64-Profile.pubxml
33+ cp ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/windows-x64/CodeQLToolkit.Core ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/windows-x64/qlt
34+
35+ # repair permissions
36+ chmod +x ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/windows-x64/qlt
37+ chmod +r -R ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/windows-x64
38+
39+ # create bundle
40+ ARCHIVE="$(pwd)/qlt-windows-x64.zip"
41+ pushd ./src/CodeQLToolkit.Core/bin/Release/net6.0/publish/windows-x64
42+ zip -r $ARCHIVE .
43+ popd
44+
45+ - name : Upload build artifacts
46+ uses : actions/upload-artifact@v3
47+ with :
48+ name : qlt-dist
49+ path : qlt*.zip
50+
51+ - name : Upload Build Artifacts
52+ shell : pwsh
53+ run : |
54+ Write-Host (Get-Location)
55+ gh release upload v${{inputs.version}} ./qlt-windows-x64.zip
56+ env :
57+ GH_TOKEN : ${{ github.token }}
Original file line number Diff line number Diff line change 2929 needs : create-draft-release
3030 with :
3131 version : ${{inputs.version}}
32+
33+ build-macos64 :
34+ uses : ./.github/workflows/internal-build-release-macos64.yml
35+ needs : create-draft-release
36+ with :
37+ version : ${{inputs.version}}
38+
39+ build-win64 :
40+ uses : ./.github/workflows/internal-build-release-win64.yml
41+ needs : create-draft-release
42+ with :
43+ version : ${{inputs.version}}
You can’t perform that action at this time.
0 commit comments