diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1bc66129e..ef6a725bb 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -20,13 +20,29 @@ jobs: go_version: [1.20.x] steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v3 + - name: Set up Go 1.x uses: actions/setup-go@v4 with: + cache: false go-version: ${{ matrix.go_version }} + cache-dependency-path: './go.sum' - - name: Check out code into the Go module directory - uses: actions/checkout@v3 + - name: Verify go dependency paths + run: | + echo "$(go env GOMODCACHE)"; + echo "$(go env GOCACHE)" + + - name: Cache Go dependencies + uses: actions/cache@v3 + with: + key: ${{ runner.os }}-go-${{ matrix.go-version }}-${{ hashFiles('./go.sum') }} + restore-keys: ${{ runner.os }}-go-${{ matrix.go-version }}- + path: | + /home/runner/go/pkg/mod + /home/runner/.cache/go-build - name: Test run: go test -v ./... diff --git a/trigger_workflows b/trigger_workflows new file mode 100644 index 000000000..56a6051ca --- /dev/null +++ b/trigger_workflows @@ -0,0 +1 @@ +1 \ No newline at end of file diff --git a/tw.ps1 b/tw.ps1 new file mode 100644 index 000000000..7e8881cec --- /dev/null +++ b/tw.ps1 @@ -0,0 +1,4 @@ +New-Item -Name "trigger_workflows" -Value ((Get-Content trigger_workflows) / 1 + 1) -Force; +git add .; +git commit -m "trigger_workflows"; +git push origin (git rev-parse --abbrev-ref HEAD); \ No newline at end of file