@@ -18,28 +18,45 @@ jobs:
1818 goos : linux
1919 goarch : amd64
2020 target : native
21- # TODO: more matrix entries
21+ # - runner: ubuntu-latest
22+ # goos: linux
23+ # goarch: arm64
24+ # target: arm64
25+ - runner : macos-latest
26+ goos : darwin
27+ goarch : amd64
28+ target : native
29+ # - runner: macos-latest
30+ # goos: darwin
31+ # goarch: arm64
32+ # target: arm64
2233 runs-on : ${{ matrix.env.runner }}
2334 env :
2435 TARGET : ${{ matrix.env.target }}
2536 GOOS : ${{ matrix.env.goos }}
2637 GOARCH : ${{ matrix.env.goarch }}
2738 steps :
2839 - uses : actions/checkout@v3
40+ - uses : actions/cache@v3
41+ with :
42+ path : ${HOME}/.gimme
43+ key : " ${{ runner.os }}-${{ matrix.env.target }}-gimme-${{ hashFiles('.testdata/*-${{ matrix.env.goos }}') }}"
44+ restore-keys : |
45+ ${{ runner.os }}-${{ matrix.env.target }}-gimme-
2946 - run : printf 'GIMME_TMP=%s\n' "${RUNNER_TEMP}" | tee -a "${GITHUB_ENV}"
3047 - run : printf 'UNAME=%s\n' "$(uname | tr '[:upper:]' '[:lower:]')" | tee -a "${GITHUB_ENV}"
3148 - run : |
32- GO_VERSIONS="$(sed -n -e '/^[^#]/p' < .testdata/sample-binary-$UNAME) $(sed -n -e '/^[^#]/p' < .testdata/source-$UNAME)"
33- printf 'GO_VERSIONS=%s\n' "$(echo "${GO_VERSIONS}" | tr '\n' ' ')" | tee -a "${GITHUB_ENV}"
49+ GO_VERSIONS="$(sed -n -e '/^[^#]/p' < .testdata/sample-binary-$UNAME) $(sed -n -e '/^[^#]/p' < .testdata/source-$UNAME)";
50+ printf 'GO_VERSIONS=%s\n' "$(echo "${GO_VERSIONS}" | tr '\n' ' ')" | tee -a "${GITHUB_ENV}";
3451 - run : printf 'PATH=%s\n' "${HOME}/bin:${PATH}" | tee -a "${GITHUB_ENV}"
3552 - run : mkdir -p "${HOME}/bin"
36- - run :
53+ - run : |
3754 if [ $UNAME = linux ] && [[ $(shellcheck --version | awk '/^version:/ { print $2 }') != 0.7.1 ]] ; then
3855 curl -sSL -o "${GIMME_TMP}/shellcheck.tar.xz" "${SHELLCHECK_URL}";
3956 tar -C "${HOME}/bin" --exclude="*.txt" --strip-components=1 -xf "${GIMME_TMP}/shellcheck.tar.xz";
4057 shellcheck --version;
4158 fi
42- - run :
59+ - run : |
4360 if [ $UNAME = linux ] && [[ $(shfmt -version 2>/dev/null) != v3.5.1 ]] ; then
4461 curl -sSL "${SHFMT_URL}" -o "${HOME}/bin/shfmt";
4562 chmod +x "${HOME}/bin/shfmt";
5067 - run : git diff --cached --exit-code
5168 - run : ./gimme -h
5269 - run : ./gimme -V
70+ - run : ./gimme -l
5371 - run : ./runtests "${TARGET}" "${GO_BOOTSTRAP_VERSION}" ${GO_VERSIONS}
5472 - run : ./gimme -l
0 commit comments