zed/.github/workflows/ci.yml

56 lines
1.2 KiB
YAML
Raw Normal View History

2021-04-03 00:43:30 +03:00
name: CI
on:
push:
branches:
- master
pull_request:
branches:
- "**"
env:
CARGO_TERM_COLOR: always
CARGO_INCREMENTAL: 0
jobs:
tests:
name: Tests
runs-on: self-hosted
2021-04-03 00:43:30 +03:00
steps:
- name: Checkout repo
uses: actions/checkout@v2
# Work around https://github.com/actions/cache/issues/403.
- name: Use GNU tar
run: |
echo PATH="/usr/local/opt/gnu-tar/libexec/gnubin:$PATH" >> $GITHUB_ENV
- name: Cache artifacts
id: cache
uses: actions/cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.rustup
2021-04-03 00:43:30 +03:00
target
key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }}
- name: Install Rust
if: steps.cache.outputs.cache-hit != 'true'
2021-04-03 00:43:30 +03:00
uses: actions-rs/toolchain@v1
with:
toolchain: stable
2021-05-05 02:34:03 +03:00
target: x86_64-apple-darwin
2021-04-03 00:43:30 +03:00
profile: minimal
- name: Run tests
2021-04-28 22:58:14 +03:00
run: cargo test --no-fail-fast
- name: Create and upload app bundle
run: script/bundle
- uses: actions/upload-artifact@v2
with:
2021-04-29 00:42:42 +03:00
name: Zed.dmg
path: target/release/Zed.dmg