Skip to content

Commit aeac4ed

Browse files
committed
ci: update ga ci and stale yml
1 parent 2affa49 commit aeac4ed

File tree

2 files changed

+69
-15
lines changed

2 files changed

+69
-15
lines changed

.github/workflows/ci.yml

Lines changed: 40 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -19,25 +19,50 @@ env:
1919

2020
jobs:
2121
test:
22-
name: Test Rust ${{ matrix.rust }} on ${{ matrix.os }}
23-
runs-on: ${{ matrix.os }}
22+
name: Test Rust ${{ matrix.name }} on ${{ matrix.target }}
23+
runs-on: ${{ matrix.runner }}
2424
continue-on-error: ${{ matrix.experimental }}
2525
strategy:
26-
fail-fast: false
2726
matrix:
2827
include:
29-
- { rust: stable, os: ubuntu-latest, experimental: false }
30-
- { rust: stable, os: macos-latest, experimental: false }
31-
- { rust: stable, os: windows-latest, experimental: true }
32-
- { rust: stable-i686-msvc, os: windows-latest, experimental: true }
33-
- { rust: beta, os: ubuntu-latest, experimental: true }
34-
- { rust: nightly, os: ubuntu-latest, experimental: true }
28+
- name: linux-amd64
29+
runner: ubuntu-latest
30+
target: x86_64-unknown-linux-gnu
31+
experimental: false
32+
toolchain: stable
33+
- name: win-amd64
34+
runner: windows-latest
35+
target: x86_64-pc-windows-msvc
36+
experimental: false
37+
toolchain: stable
38+
- name: macos-amd64
39+
runner: macos-latest
40+
target: x86_64-apple-darwin
41+
experimental: false
42+
toolchain: stable
43+
- name: macos-arm64
44+
runner: macos-latest
45+
target: aarch64-apple-darwin
46+
experimental: false
47+
toolchain: stable
48+
- name: linux-amd64
49+
runner: ubuntu-latest
50+
target: x86_64-unknown-linux-gnu
51+
experimental: true
52+
toolchain: beta
53+
- name: linux-amd64
54+
runner: ubuntu-latest
55+
target: x86_64-unknown-linux-gnu
56+
experimental: true
57+
toolchain: nightly
3558
steps:
36-
- uses: actions/checkout@v4
37-
- uses: hecrj/setup-rust-action@v2
59+
- name: Checkout
60+
uses: actions/checkout@v4
61+
- name: Rust toolchain
62+
uses: dtolnay/rust-toolchain@master
3863
with:
39-
rust-version: ${{ matrix.rust }}
40-
64+
toolchain: "${{ matrix.toolchain }}"
65+
targets: "${{ matrix.target }}"
4166
- run: cargo build --verbose --all
4267
- run: cargo build --release
4368
- run: cargo test --verbose --all -- --nocapture
@@ -55,7 +80,7 @@ jobs:
5580
RUSTFLAGS: -Dwarnings
5681
steps:
5782
- uses: actions/checkout@v4
58-
- uses: hecrj/setup-rust-action@v2
83+
- uses: dtolnay/rust-toolchain@stable
5984
with:
6085
components: clippy
6186
- run: cargo clippy --workspace --all-targets --verbose
@@ -67,7 +92,7 @@ jobs:
6792
runs-on: ubuntu-latest
6893
steps:
6994
- uses: actions/checkout@v4
70-
- uses: hecrj/setup-rust-action@v2
95+
- uses: dtolnay/rust-toolchain@stable
7196
with:
7297
components: rustfmt
7398
- run: cargo fmt --all -- --check

.github/workflows/stale.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: stale
2+
on:
3+
schedule:
4+
- cron: "30 1 * * *"
5+
workflow_dispatch:
6+
7+
permissions:
8+
issues: write
9+
pull-requests: write
10+
discussions: write
11+
12+
jobs:
13+
stale:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/stale@v8
17+
with:
18+
stale-issue-message: "This issue has been marked stale due to no recent activity."
19+
stale-pr-message: "This PR has been marked stale due to no recent activity."
20+
close-issue-message: "This issue was closed due to no activity for an extended period."
21+
close-pr-message: "This PR was closed due to no activity for an extended period."
22+
days-before-issue-stale: 30
23+
days-before-pr-stale: 45
24+
days-before-issue-close: 5
25+
days-before-pr-close: 10
26+
- uses: dessant/lock-threads@v5
27+
with:
28+
exclude-any-issue-labels: "help wanted, upstream, in progress"
29+
process-only: "issues"

0 commit comments

Comments
 (0)