mirror of
https://github.com/velopack/velopack.git
synced 2025-10-25 15:19:22 +00:00
Package up artifacts for release
This commit is contained in:
43
.github/workflows/build.yml
vendored
43
.github/workflows/build.yml
vendored
@@ -30,6 +30,11 @@ jobs:
|
||||
key: "rust-test-${{ matrix.os }}"
|
||||
- name: Install cargo-llvm-cov
|
||||
uses: taiki-e/install-action@cargo-llvm-cov
|
||||
- name: Check lib-nodejs
|
||||
working-directory: src/lib-nodejs
|
||||
run: |
|
||||
npm install
|
||||
npm run build
|
||||
- name: Check lib-rust
|
||||
run: cargo check -p velopack -F async,delta
|
||||
- name: Check RustIced Sample
|
||||
@@ -39,9 +44,7 @@ jobs:
|
||||
run: cargo llvm-cov ${{ matrix.rust_flags }} --cobertura --output-path ./test/coverage.rust.${{ matrix.os }}.xml
|
||||
- name: Test lib-nodejs
|
||||
working-directory: src/lib-nodejs
|
||||
run: |
|
||||
npm install
|
||||
npm run test
|
||||
run: npm run test
|
||||
- name: Upload Coverage
|
||||
uses: codecov/codecov-action@v4
|
||||
with:
|
||||
@@ -138,8 +141,6 @@ jobs:
|
||||
|
||||
build-rust-macos:
|
||||
runs-on: macos-latest
|
||||
env:
|
||||
RUSTFLAGS: -C target-feature=+crt-static
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
@@ -260,7 +261,7 @@ jobs:
|
||||
env:
|
||||
VELOPACK_CROSS_ARTIFACTS: true
|
||||
run: dotnet test test/Velopack.Packaging.Tests/Velopack.Packaging.Tests.csproj --no-build -c Release --filter "FullyQualifiedName~RunCrossApp" -l "console;verbosity=detailed;consoleLoggerParameters=ErrorsOnly" -l GithubActions -- RunConfiguration.CollectSourceInformation=true
|
||||
|
||||
|
||||
package:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [build-rust-windows, build-rust-linux, build-rust-macos]
|
||||
@@ -299,10 +300,38 @@ jobs:
|
||||
with:
|
||||
name: packages
|
||||
path: build/Release/*nupkg
|
||||
|
||||
organise-artifacts:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [package, test-dotnet]
|
||||
steps:
|
||||
- name: Download
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
path: bin-core
|
||||
pattern: rust-*
|
||||
merge-multiple: true
|
||||
- name: Rearrange
|
||||
run: |
|
||||
mkdir bin-nodejs
|
||||
mv bin-core/*.node bin-nodejs/
|
||||
- name: Upload Core
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bin-core
|
||||
path: bin-core/*
|
||||
- name: Upload Node
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bin-nodejs
|
||||
path: bin-nodejs/*
|
||||
- uses: geekyeggo/delete-artifact@v5
|
||||
with:
|
||||
name: rust-*
|
||||
|
||||
release:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [package, test-dotnet, test-rust]
|
||||
needs: [package, test-dotnet, test-rust, organise-artifacts]
|
||||
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
|
||||
steps:
|
||||
- name: Invoke Release Workflow
|
||||
|
||||
2
.github/workflows/release.yml
vendored
2
.github/workflows/release.yml
vendored
@@ -104,4 +104,4 @@ jobs:
|
||||
run: |
|
||||
for f in packages/*.nupkg; do
|
||||
dotnet nuget push "$f" -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json --skip-duplicate
|
||||
done
|
||||
done
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
param(
|
||||
[string]$version = $(nbgv get-version -v NuGetPackageVersion).Trim()
|
||||
)
|
||||
|
||||
$scriptDir = $PSScriptRoot
|
||||
$path = Join-Path $scriptDir "Cargo.toml"
|
||||
$version = (nbgv get-version -v NuGetPackageVersion).Trim()
|
||||
Write-Host "Setting version to $version"
|
||||
|
||||
(Get-Content $path) | ForEach-Object {
|
||||
@@ -12,7 +15,5 @@ Write-Host "Setting version to $version"
|
||||
}
|
||||
} | Set-Content $path
|
||||
|
||||
cargo pkgid -p velopack
|
||||
|
||||
Set-Location "$scriptDir/src/lib-nodejs"
|
||||
npm version $version --no-git-tag-version
|
||||
Reference in New Issue
Block a user