Skip to content

Commit 5e98d4b

Browse files
committed
chore(ci): install restic in test env
1 parent d243c92 commit 5e98d4b

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

.github/workflows/ci.yml

+14
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,25 @@ on:
44
push:
55
branches: [master]
66

7+
env:
8+
RESTIC_VERSION: "0.17.1"
9+
710
jobs:
811
test:
912
runs-on: ubuntu-latest
1013
steps:
1114
- uses: actions/checkout@v3
15+
16+
- name: Install restic@${{ env.RESTIC_VERSION }}
17+
run: |
18+
mkdir -p tools/restic
19+
curl --fail --location --silent --show-error --output tools/restic/restic.bz2 \
20+
"https://github.com/restic/restic/releases/download/v${RESTIC_VERSION}/restic_${RESTIC_VERSION}_linux_amd64.bz2"
21+
bzip2 -d tools/restic/restic.bz2
22+
chmod +x tools/restic/restic
23+
echo "$GITHUB_WORKSPACE/tools/restic" >> "$GITHUB_PATH"
24+
- run: restic version
25+
1226
- uses: actions/setup-go@v3
1327
with:
1428
go-version: '^1.21'

0 commit comments

Comments
 (0)