add license details #19
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
# Managed by infra via Terraform, edits will be lost | |
name: rust-library | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
env: | |
CARGO_NET_GIT_FETCH_WITH_CLI: true | |
jobs: | |
test: | |
name: rust | |
runs-on: ubuntu-latest-8-cores | |
if: github.actor != 'bitdriftlabs-terraform[bot]' | |
strategy: | |
matrix: | |
rust: ['stable'] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
# Get a token that can be used for org read-only clones. | |
- name: org-read-only-install token | |
id: org-read-only | |
uses: getsentry/action-github-app-token@v2 | |
with: | |
app_id: ${{ secrets.ORG_READ_ONLY_APP_ID }} | |
private_key: ${{ secrets.ORG_READ_ONLY_APP_PRIVATE_KEY }} | |
# Install the token so all ssh pulls are rewritten to use the token from the previous step. | |
- name: setup git credentials | |
uses: de-vri-es/setup-git-credentials@v2 | |
with: | |
credentials: https://x-access-token:${{ steps.org-read-only.outputs.token }}@github.com/ | |
- name: Rust Toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: ${{ matrix.rust }} | |
override: true | |
profile: minimal | |
- name: Cache | |
uses: Swatinem/rust-cache@a95ba195448af2da9b00fb742d14ffaaf3c21f43 | |
- name: CI Setup | |
run: if [[ -f ci/setup.sh ]]; then ci/setup.sh; fi | |
- name: Build Workspace | |
run: | | |
if test -f "Makefile"; then | |
make build | |
else | |
cargo build --workspace | |
fi | |
- name: Test Workspace | |
run: | | |
if test -f "Makefile"; then | |
make test | |
else | |
cargo test --workspace | |
fi |