Add macos and windows runners to CI #468
Workflow file for this run
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
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
name: Test | |
jobs: | |
test: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- ubuntu-latest | |
- macos-latest | |
- windows-latest | |
name: Test | |
env: | |
PROJECT_NAME_UNDERSCORE: git_ps_ci_github_actions_workflow | |
CARGO_INCREMENTAL: 0 | |
# RUSTFLAGS: -Zprofile -Ccodegen-units=1 -Copt-level=0 -Clink-dead-code -Coverflow-checks=off -Zpanic_abort_tests -Cpanic=abort | |
# RUSTDOCFLAGS: -Cpanic=abort | |
runs-on: ${{matrix.os}} | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions-rs/toolchain@v1 | |
with: | |
profile: minimal | |
toolchain: stable | |
override: true | |
- name: Cache dependencies | |
uses: actions/cache@v2 | |
env: | |
cache-name: cache-dependencies | |
with: | |
path: | | |
~/.cargo/.crates.toml | |
~/.cargo/.crates2.json | |
~/.cargo/bin | |
~/.cargo/registry/index | |
~/.cargo/registry/cache | |
target | |
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('Cargo.lock') }} | |
- name: Install GPGME (unix) | |
if : ${{ matrix.os == 'ubuntu-latest' }} | |
run: sudo apt-get install -y libgpgme-dev | |
- name: Install GPGME (macos) | |
if : ${{ matrix.os == 'macos-latest' }} | |
run: brew update && brew install gpgme | |
- name: Install GPGME (windows) | |
if: ${{ false }} | |
# if : ${{ matrix.os == 'windows-latest' }} | |
env: | |
GNUPG_VERSION: 2.3.8_20221013 | |
run: | | |
curl "https://gnupg.org/ftp/gcrypt/binary/gnupg-w32-${GNUPG_VERSION}.exe" --output gnupg.exe | |
./gnupg.exe | |
- name: Run Tests | |
run: | | |
cargo test |