forked from anoma/namada
-
Notifications
You must be signed in to change notification settings - Fork 0
75 lines (70 loc) · 2.21 KB
/
cron.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
name: Run period checks
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
permissions:
id-token: write
contents: read
issues: write
env:
GIT_LFS_SKIP_SMUDGE: 1
CARGO_INCREMENTAL: 0
RUST_BACKTRACE: full
jobs:
cron:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
nightly_version: [nightly-2023-06-01]
make:
- name: Audit
command: audit
version: rustsec/rustsec@cargo-audit/v0.17.6
- name: Unused dependencies
command: udeps
version: est31/cargo-udeps@v0.1.42
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Setup rust nightly
uses: oxidecomputer/actions-rs_toolchain@ad3f86084a8a5acf2c09cb691421b31cf8af7a36
with:
toolchain: ${{ matrix.nightly_version }}
profile: minimal
- name: Show rust toolchain info
run: rustup show
- name: Cache cargo registry
uses: actions/cache@v3
continue-on-error: false
with:
path: |
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target
key: ${{ runner.os }}-${{ github.job }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: ${{ runner.os }}-cargo-
- name: Install cargo ${{ matrix.make.command }}
run: curl https://i.jpillora.com/${{ matrix.make.version }}! | bash
- name: Install libudev
run: sudo apt-get update && sudo apt-get -y install libudev-dev
- name: Install Protoc
uses: heliaxdev/setup-protoc@v2
with:
version: "25.0"
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: ${{ matrix.make.name }}
working-directory: ./.github/workflows/scripts
run: |
pip3 install -Iv cryptography==37.0.4 >/dev/null 2>&1
pip3 install github3.py >/dev/null 2>&1
python3 ${{ matrix.make.command }}.py
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Clean cargo cache
run: |
cargo install cargo-cache --no-default-features --features ci-autoclean cargo-cache
cargo-cache