-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes #485 And switches workflows to GitHub from Azure
- Loading branch information
1 parent
4d31282
commit 2d1fc07
Showing
5 changed files
with
157 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
name: "Cache Zigs" | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
|
||
matrix: | ||
name: Generate test matrix | ||
runs-on: ubuntu-latest | ||
outputs: | ||
matrix-json: ${{ steps.set-matrix.outputs.matrix }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
repository: rinse-repeat/zig-gh-helper | ||
path: zig-helper | ||
- id: set-matrix | ||
run: | | ||
echo "ZIG_VERSION=${{ inputs.zig-version }}" | tee -a $GITHUB_ENV | ||
content=`cat ./zig-helper/matrix.json` | ||
# the following lines are only required for multi line json | ||
content="${content//'%'/'%25'}" | ||
content="${content//$'\n'/'%0A'}" | ||
content="${content//$'\r'/'%0D'}" | ||
# end of optional handling for multi line json | ||
echo "::set-output name=matrix::$content" | ||
install-zig: | ||
needs: [matrix] | ||
uses: rinse-repeat/zig-gh-helper/.github/workflows/zig_install.yml@main | ||
with: | ||
os: ${{ matrix.os }} | ||
use-cache: true | ||
ext-cache: AAB | ||
zig-version: 0.9.1 | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: ${{ fromJson(needs.matrix.outputs.matrix-json) }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: [ '**' ] | ||
pull_request: | ||
branches: [ '**' ] | ||
|
||
env: | ||
CARGO_TERM_COLOR: 'always' | ||
RUSTFLAGS: '-D warnings' | ||
|
||
jobs: | ||
test-stable: | ||
name: Test stable | ||
runs-on: ${{ matrix.runs-on }} | ||
strategy: | ||
matrix: | ||
include: | ||
# Linux | ||
- runs-on: ubuntu-latest | ||
# Windows | ||
- runs-on: windows-latest | ||
# MacOS | ||
- runs-on: macos-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@stable | ||
- run: cargo test -- --skip args::args_tests::update_config_test_color_choice::case_4 --skip test_package | ||
|
||
# TODO: Address clippy | ||
# clippy: | ||
# name: Check that clippy is happy | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
# - uses: actions/checkout@v3 | ||
# - uses: dtolnay/rust-toolchain@1.73.0 | ||
# with: | ||
# components: clippy | ||
# - run: cargo clippy --target x86_64-unknown-linux-gnu --all-features | ||
|
||
rustfmt: | ||
name: Check formatting | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@stable | ||
with: | ||
components: rustfmt | ||
- run: cargo fmt --all -- --check |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
name: "Cargo-geiger Release Builder" | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
tag: | ||
description: 'Release tag' | ||
required: true | ||
type: string | ||
|
||
jobs: | ||
|
||
matrix: | ||
name: Generate Matrix | ||
runs-on: ubuntu-latest | ||
outputs: | ||
matrix-json: ${{ steps.set-matrix.outputs.matrix }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
path: release-repo | ||
- id: set-matrix | ||
run: | | ||
content=`cat ./release-repo/matrix.json` | ||
# the following lines are only required for multi line json | ||
content="${content//'%'/'%25'}" | ||
content="${content//$'\n'/'%0A'}" | ||
content="${content//$'\r'/'%0D'}" | ||
# end of optional handling for multi line json | ||
echo "::set-output name=matrix::$content" | ||
build: | ||
needs: [matrix] | ||
uses: rinse-repeat/auditable-builder/.github/workflows/rust-builder.yml@main | ||
with: | ||
repository: geiger-rs/cargo-geiger | ||
rust-target: ${{ matrix.rust-target }} | ||
os: ${{ matrix.os }} | ||
rust: ${{ matrix.rust }} | ||
use-features: ${{ matrix.use-features }} | ||
use-cache: true | ||
use-locked: true | ||
serial: AAB | ||
zig-version: 0.9.1 | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: ${{ fromJson(needs.matrix.outputs.matrix-json) }} | ||
|
||
release: | ||
needs: [build] | ||
uses: rinse-repeat/auditable-builder/.github/workflows/release-builder.yml@main | ||
with: | ||
repository: geiger-rs/cargo-geiger | ||
tag: ${{ github.event.inputs.tag }} | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
[ | ||
{"rust-target": "x86_64-pc-windows-msvc" , "os": "windows-latest" , "rust": "stable"}, | ||
{"rust-target": "i686-pc-windows-msvc" , "os": "windows-latest" , "rust": "stable"}, | ||
{"rust-target": "aarch64-pc-windows-msvc" , "os": "windows-latest" , "rust": "stable"}, | ||
{"rust-target": "armv7-unknown-linux-gnueabihf" , "os": "ubuntu-latest" , "rust": "stable", "use-features": "vendored-openssl"}, | ||
{"rust-target": "arm-unknown-linux-gnueabihf" , "os": "ubuntu-latest" , "rust": "stable", "use-features": "vendored-openssl"}, | ||
{"rust-target": "x86_64-unknown-linux-gnu" , "os": "ubuntu-latest" , "rust": "stable"}, | ||
{"rust-target": "aarch64-unknown-linux-gnu" , "os": "ubuntu-latest" , "rust": "stable", "use-features": "vendored-openssl"}, | ||
{"rust-target": "x86_64-apple-darwin" , "os": "macos-latest" , "rust": "stable"}, | ||
{"rust-target": "aarch64-apple-darwin" , "os": "macos-latest" , "rust": "stable", "use-features": "vendored-openssl"} | ||
] |