-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
52 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -48,6 +48,7 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v4 | ||
- name: DEBUG | ||
shell: bash | ||
run: | | ||
cat <<'DEBUG_DOC' | ||
== DEBUG ======================================================= | ||
|
@@ -59,7 +60,6 @@ jobs: | |
${{ toJSON(github) }} | ||
================================================================ | ||
DEBUG_DOC | ||
shell: bash | ||
- name: actions/cache for versenv | ||
uses: actions/cache@v3 | ||
with: | ||
|
@@ -69,6 +69,7 @@ jobs: | |
restore-keys: | | ||
versenv-${{ runner.os }}- | ||
- name: Add GITHUB_PATH, GITHUB_ENV | ||
shell: bash | ||
run: | | ||
# Update GITHUB_PATH | ||
cat <<GITHUB_PATH >> $GITHUB_PATH | ||
|
@@ -79,6 +80,7 @@ jobs: | |
# Update GITHUB_ENV | ||
grep -Ev '^\s*$|^\s*#' .versenv.env >> $GITHUB_ENV | ||
- name: Setup versenv | ||
shell: bash | ||
run: | | ||
# Setup versenv | ||
direnv allow ${{ env.WORKDIR }} | ||
|
@@ -90,6 +92,7 @@ jobs: | |
go-version-file: ${{ env.WORKDIR }}/go.mod | ||
- name: Get Golang info | ||
id: golang-info | ||
shell: bash | ||
run: | | ||
echo "GOVERSION=$(go version | cut -d' ' -f3)" >> "$GITHUB_OUTPUT" | ||
echo "GOCACHE=$(go env GOCACHE)" >> "$GITHUB_OUTPUT" | ||
|
@@ -104,14 +107,16 @@ jobs: | |
${{ runner.os }}-go-${{ steps.golang-info.outputs.GOVERSION }}-${{ hashFiles('**/go.sum') }}- | ||
${{ runner.os }}-go-${{ steps.golang-info.outputs.GOVERSION }}- | ||
${{ runner.os }}-go- | ||
# - name: Run go mod tidy | ||
# if: ${{ steps.setup-go.outputs.cache-hit != 'true' }} | ||
# env: | ||
# DEBIAN_FRONTEND: noninteractive | ||
# # GITHUB_TOKEN: ${{ secrets.GH_BOT_TOKEN }} | ||
# working-directory: ${{ env.WORKDIR }} | ||
# run: | | ||
# direnv exec . go-mod-tidy-all | ||
- name: Setup git config for go mod download | ||
env: | ||
DEBIAN_FRONTEND: noninteractive | ||
# GITHUB_TOKEN: ${{ secrets.GH_BOT_TOKEN }} | ||
working-directory: ${{ env.WORKDIR }} | ||
shell: bash | ||
run: | | ||
set -Eeu -o pipefail -x | ||
direnv allow . | ||
direnv exec . bash -Eeux -o pipefail -c 'echo "${GOPRIVATE:-}${GOPRIVATE+,}" | while read -d , -r LINE; do echo "set git config: ${LINE}"; git config --global url."https://${GITHUB_TOKEN}:x-oauth-basic@${LINE}".insteadOf "https://${LINE}"; done' | ||
- uses: golangci/[email protected] # ref. https://github.com/golangci/golangci-lint-action#how-to-use | ||
with: | ||
working-directory: ${{ env.WORKDIR }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters