Skip to content

Commit e818a08

Browse files
committed
improve ci
1 parent 69040b7 commit e818a08

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

.github/workflows/tests.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,10 @@ jobs:
3434

3535
runs-on: ${{ matrix.os }}
3636

37+
concurrency:
38+
group: ${{ github.workflow }}-${{ github.ref }}
39+
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
40+
3741
env:
3842
HF_TOKEN: ${{ secrets.HF_TOKEN }}
3943
OS_NAME: ${{ matrix.os }}
@@ -54,6 +58,14 @@ jobs:
5458
python -m pip install --upgrade pip
5559
python -m pip install ".[torch,dev]"
5660
61+
- name: Cache files
62+
uses: actions/cache@v4
63+
with:
64+
path: |
65+
/home/runner/.cache/huggingface/hub/datasets--*
66+
/home/runner/.cache/huggingface/hub/models--*
67+
key: ${{ runner.os }}-hf-hub-cache-${{ hashFiles('**/conftest.py') }}
68+
5769
- name: Check quality
5870
run: |
5971
make style && make quality

0 commit comments

Comments
 (0)