forked from exercism/configlet
-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (47 loc) · 1.29 KB
/
fetch-configlet.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: Fetch configlet
on:
push:
paths:
- scripts/fetch-configlet*
pull_request:
paths:
- scripts/fetch-configlet*
workflow_dispatch:
jobs:
fetch_configlet:
strategy:
fail-fast: false
matrix:
include:
- os: linux
runs-on: ubuntu-22.04
- os: macos
runs-on: macos-12
- os: windows
runs-on: windows-2022
name: fetch-configlet-${{ matrix.os }}
runs-on: ${{ matrix.runs-on }}
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332
- name: Run fetch-configlet
shell: bash
run: ./scripts/fetch-configlet
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Run the downloaded configlet
env:
EXT: ${{ matrix.os == 'windows' && '.exe' || '' }}
shell: bash
run: |
configlet_path="./bin/configlet${EXT}"
"${configlet_path}" --version
- name: On Windows, also test fetch-configlet.ps1
if: matrix.os == 'windows'
shell: pwsh
run: |
Remove-Item bin/configlet.exe
scripts/fetch-configlet.ps1
bin/configlet.exe --version
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}