1
0
Fork 0
mirror of synced 2024-04-24 15:52:07 +12:00
czkawka/.github/workflows/mac.yml
2020-12-16 11:20:42 +01:00

50 lines
1.2 KiB
YAML

name: 🍎 MacOS
on: [ push, pull_request ]
env:
CARGO_TERM_COLOR: always
jobs:
macos-cli:
strategy:
matrix:
toolchain: [ stable ]
type: [ release ]
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.toolchain }}
override: true
- uses: actions/cache@v2
with:
path: |
target
key: mac-cli-${{github.ref}}-${{github.sha}}
restore-keys: |
mac-cli-${{github.ref}}-${{github.sha}}
- name: Build CLI Debug
run: cargo build --bin czkawka_cli
env:
CARGO_INCREMENTAL: 0
RUSTFLAGS: "-C debuginfo=0 -D warnings"
if: ${{ matrix.type == 'debug'}}
- name: Build CLI Release
run: cargo build --release --bin czkawka_cli
env:
CARGO_INCREMENTAL: 0
RUSTFLAGS: "-C debuginfo=0 -D warnings"
if: ${{ matrix.type == 'release'}}
- name: Store MacOS CLI
uses: actions/upload-artifact@v2
with:
name: czkawka_cli-${{ runner.os }}-${{ matrix.toolchain }}
path: target/release/czkawka_cli
if: ${{ matrix.type == 'release' }}