Skip to content

Commit 2c30b53

Browse files
committed
update e2e.yml
1 parent 663ad69 commit 2c30b53

File tree

3 files changed

+11
-17
lines changed

3 files changed

+11
-17
lines changed

.github/workflows/e2e.yml

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -37,24 +37,18 @@ jobs:
3737
run: |
3838
git clone --depth=1 https://github.com/${{ github.event.inputs.target_repo || 'llvm/llvm-project' }}.git test-repo
3939
40-
- name: Create .pre-commit-config.yaml
40+
- name: Install pre-commit hooks and run
4141
run: |
4242
cd test-repo
43-
rm -f .pre-commit-config.yaml
43+
rm -f .pre-commit-config.yaml || true
4444
cat > .pre-commit-config.yaml << EOF
4545
repos:
4646
- repo: https://github.com/cpp-linter/cpp-linter-hooks
47-
rev: main
47+
rev: ${{ github.sha }}
4848
hooks:
4949
- id: clang-format
50-
args: [
51-
--style=LLVM,
52-
--version=${{ matrix.clang_version }}
53-
]
50+
args: [--style=LLVM, --version=${{ matrix.clang_version }}]
5451
EOF
5552
56-
- name: Install and run cpp-linter-hooks
57-
run: |
58-
cd test-repo
5953
pre-commit install
6054
pre-commit run --all-files

.github/workflows/pre-commit.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ name: pre-commit
22

33
on:
44
push:
5-
branches: main
5+
branches: [main]
66
pull_request:
7-
branches: main
7+
branches: [main]
88
workflow_dispatch:
99

1010
jobs:

.github/workflows/test.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ name: Test
22

33
on:
44
push:
5-
branches: main
5+
branches: [main]
66
pull_request:
7-
branches: main
7+
branches: [main]
88
workflow_dispatch:
99

1010
jobs:
@@ -15,10 +15,10 @@ jobs:
1515
python-version: ["3.14", "3.13", "3.12", "3.11", "3.10", "3.9"]
1616
steps:
1717
- name: Checkout
18-
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 #v5
18+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 #v5.0.0
1919

2020
- name: Set up Python ${{ matrix.python-version }}
21-
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c #v5
21+
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c #v5.0.0
2222
with:
2323
python-version: ${{ matrix.python-version }}
2424

@@ -32,7 +32,7 @@ jobs:
3232
coverage run --source=tests,cpp_linter_hooks -m pytest -vv
3333
coverage report
3434
coverage xml
35-
- uses: codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 #v5
35+
- uses: codecov/codecov-action@5a1091511ad55cbe89839c7260b706298ca349f7 #v5.0.1
3636
if: matrix.python-version == '3.13'
3737
with:
3838
token: ${{ secrets.CODECOV_TOKEN }}

0 commit comments

Comments
 (0)