Skip to content

Add explicit permissions to workflows (#30) #84

Add explicit permissions to workflows (#30)

Add explicit permissions to workflows (#30) #84

Workflow file for this run

name: Rust
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions: read-all
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Cache
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Build
working-directory: .
run: cargo build --verbose
- name: Run tests
working-directory: .
run: cargo test --verbose