Skip to content

Commit b74c813

Browse files
committed
fix ci and update all used actions
1 parent 00e6e32 commit b74c813

File tree

3 files changed

+24
-18
lines changed

3 files changed

+24
-18
lines changed

.github/actions/setup-rust/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ runs:
3333
echo "CC=clang" >> $GITHUB_ENV
3434
echo "PKG_CONFIG_SYSROOT_DIR=/" >> $GITHUB_ENV
3535
36-
- uses: actions/cache@v3
36+
- uses: actions/cache@v4
3737
with:
3838
path: |
3939
~/.cargo/bin/
@@ -46,7 +46,7 @@ runs:
4646
# Remove build artifacts for the current crate, since it will be rebuilt every
4747
# run anyway, but keep dependency artifacts to cache them.
4848
# Must be placed after actions/cache so its post step runs first.
49-
- uses: pyTooling/Actions/with-post-step@v0.4.6
49+
- uses: pyTooling/Actions/with-post-step@v4.1.0
5050
with:
5151
main: bash ./.github/actions/setup-rust/cleanup.sh
5252
post: bash ./.github/actions/setup-rust/cleanup.sh

.github/workflows/ci.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
style:
1818
runs-on: ubuntu-22.04
1919
steps:
20-
- uses: actions/checkout@v3
20+
- uses: actions/checkout@v4
2121
- name: Setup Rust
2222
uses: ./.github/actions/setup-rust
2323
with:
@@ -55,7 +55,7 @@ jobs:
5555
run:
5656
shell: bash
5757
steps:
58-
- uses: actions/checkout@v3
58+
- uses: actions/checkout@v4
5959
- uses: actionhippie/swap-space@v1
6060
if: matrix.use_swap
6161
with:
@@ -88,7 +88,7 @@ jobs:
8888
echo "$PWD/target/release" >> $GITHUB_PATH
8989
- name: Publish release binary artifact
9090
if: matrix.publish
91-
uses: actions/upload-artifact@v3
91+
uses: actions/upload-artifact@v4
9292
with:
9393
path: target/${{ matrix.target }}/release/scryer-prolog*
9494
name: scryer-prolog_${{ matrix.os }}_${{ matrix.target }}
@@ -99,7 +99,7 @@ jobs:
9999
needs: [build-test]
100100
steps:
101101
# Download prebuilt ubuntu binary from build-test job, setup logtalk
102-
- uses: actions/download-artifact@v3
102+
- uses: actions/download-artifact@v4
103103
with:
104104
name: scryer-prolog_ubuntu-20.04_x86_64-unknown-linux-gnu
105105
- run: |
@@ -123,12 +123,12 @@ jobs:
123123
|| echo "::warning ::logtalk compliance suite failed"
124124
# -u "https://github.com/LogtalkDotOrg/logtalk3/tree/$LOGTALK_GIT_HASH/tests/prolog/" \
125125
- name: Publish Logtalk test logs
126-
uses: actions/upload-artifact@v3
126+
uses: actions/upload-artifact@v4
127127
with:
128128
name: logtalk-test-logs
129129
path: '${{ env.LOGTALKUSER }}/tests/prolog/logtalk_tester_logs'
130130
- name: Publish Logtalk test results artifact
131-
uses: actions/upload-artifact@v3
131+
uses: actions/upload-artifact@v4
132132
with:
133133
name: logtalk-test-results
134134
path: '${{ env.LOGTALKUSER }}/tests/prolog/**/*.xml'
@@ -143,7 +143,7 @@ jobs:
143143
report:
144144
runs-on: ubuntu-22.04
145145
steps:
146-
- uses: actions/checkout@v3
146+
- uses: actions/checkout@v4
147147
- name: Setup Rust
148148
uses: ./.github/actions/setup-rust
149149
with:
@@ -162,7 +162,7 @@ jobs:
162162
run: |
163163
RUSTC_BOOTSTRAP=1 cargo test --all -- -Z unstable-options --format json --report-time | cargo2junit > cargo_test_results.xml
164164
- name: Publish cargo test results artifact
165-
uses: actions/upload-artifact@v3
165+
uses: actions/upload-artifact@v4
166166
with:
167167
name: cargo-test-results
168168
path: cargo_test_results.xml
@@ -181,7 +181,7 @@ jobs:
181181
- run: cargo bench --bench run_criterion -- --profile-time 60
182182

183183
- name: Publish benchmark results
184-
uses: actions/upload-artifact@v3
184+
uses: actions/upload-artifact@v4
185185
with:
186186
name: benchmark-results
187187
path: |
@@ -195,7 +195,7 @@ jobs:
195195
needs: [build-test]
196196
if: startsWith(github.ref, 'refs/tags/v')
197197
steps:
198-
- uses: actions/download-artifact@v3
198+
- uses: actions/download-artifact@v4
199199
- name: Zip binaries for release
200200
run: |
201201
zip scryer-prolog_macos-11.zip ./scryer-prolog_macos-11_x86_64-apple-darwin/scryer-prolog
@@ -204,7 +204,7 @@ jobs:
204204
zip scryer-prolog_windows-latest.zip ./scryer-prolog_windows-latest_x86_64-pc-windows-msvc/scryer-prolog.exe
205205
zip scryer-prolog_wasm32.zip ./scryer-prolog_ubuntu-22.04_wasm32-unknown-unknown/scryer-prolog.wasm
206206
- name: Release
207-
uses: softprops/action-gh-release@v1
207+
uses: softprops/action-gh-release@v2
208208
with:
209209
files: |
210210
scryer-prolog_macos-11.zip

.github/workflows/docker-publish.yml

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,17 +14,17 @@ jobs:
1414

1515
steps:
1616
- name: Checkout repository
17-
uses: actions/checkout@v3
17+
uses: actions/checkout@v4
1818

1919
# Workaround: https://github.com/docker/build-push-action/issues/461
2020
- name: Setup Docker buildx
2121
# https://github.com/docker/setup-buildx-action
22-
uses: docker/setup-buildx-action@v2.2.1
22+
uses: docker/setup-buildx-action@v3
2323

2424
# Login against Docker registry
2525
- name: Log into registry
2626
# https://github.com/docker/login-action
27-
uses: docker/login-action@v2.1.0
27+
uses: docker/login-action@v3
2828
with:
2929
username: ${{ secrets.DOCKERHUB_USERNAME }}
3030
password: ${{ secrets.DOCKERHUB_TOKEN }}
@@ -35,7 +35,7 @@ jobs:
3535
- name: Extract Docker metadata
3636
id: meta
3737
# https://github.com/docker/metadata-action
38-
uses: docker/metadata-action@v4.1.1
38+
uses: docker/metadata-action@v5
3939
with:
4040
images: docker.io/${{ secrets.DOCKERHUB_USERNAME }}/scryer-prolog
4141
tags: |
@@ -47,7 +47,13 @@ jobs:
4747
- name: Build and push Docker image
4848
id: build-and-push
4949
# https://github.com/docker/build-push-action
50-
uses: docker/build-push-action@v3.2.0
50+
uses: docker/build-push-action@v6
51+
# v4 adds SLSA Provenance attestation which is
52+
# - unsupported by AWS Lambda
53+
# - limited support by Google Cloud Run
54+
# > If deploying a multi-architecture image, the manifest list must include linux/amd64.
55+
# see https://github.com/docker/build-push-action/releases/tag/v4.0.0
56+
# we might want to disable this if its a problem for someone
5157
with:
5258
context: .
5359
push: true

0 commit comments

Comments
 (0)