Skip to content

Commit

Permalink
Update CI dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
Frassle committed Mar 9, 2024
1 parent 8a1864e commit 93c9904
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 16 deletions.
24 changes: 14 additions & 10 deletions .github/workflows/stage-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ permissions: read-all

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GOLANGCI_LINT_VERSION: v1.53
GOLANGCI_LINT_VERSION: v1.55
GO_VERSION: v1.21.x

jobs:
lint:
Expand All @@ -16,22 +17,25 @@ jobs:
- name: Checkout Repo
uses: actions/checkout@v2
- name: Set up Go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
go-version: 1.20.x
# golangci-lint-action handles all the caching for Go.
cache: false
go-version: ${{ env.GO_VERSION }}
cache-dependency-path: |
**/go.sum
- run: go mod tidy -go=1.19
- name: Fail if god mod not tidy
- name: Fail if go mod tidy changed go.mod
run: |
if [ -n "$(git status --porcelain)" ]; then
echo "::error go.mod not tidy"
exit 1
fi
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
uses: golangci/golangci-lint-action@v4
with:
# Caching was done by actions/setup-go
skip-cache: true
skip-pkg-cache: true
skip-build-cache: true
version: ${{ env.GOLANGCI_LINT_VERSION }}

check-copyright:
Expand All @@ -44,8 +48,8 @@ jobs:
with:
repo: pulumi/pulumictl
- name: Set up Go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
go-version: 1.20.x
go-version: 1.21.x
- name: Lint
run: make lint-copyright
4 changes: 2 additions & 2 deletions .github/workflows/stage-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ jobs:
- name: Unshallow clone for tags
run: git fetch --prune --unshallow --tags || true
- name: Install Go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
go-version: 1.20.x
go-version: 1.21.x
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/stage-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
with:
ref: ${{ inputs.commit-ref }}
- name: Install Go
uses: actions/setup-go@v4
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Set up Python ${{ inputs.python-version }}
Expand Down Expand Up @@ -146,4 +146,4 @@ jobs:
strategy:
fail-fast: false
matrix:
go-version: [1.20.x]
go-version: [1.21.x]
3 changes: 1 addition & 2 deletions pkg/pulumiyaml/sort_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,8 @@ func diagString(d *syntax.Diagnostic) string {
return fmt.Sprintf("%v:%v:%v: %s", d.Subject.Filename, d.Subject.Start.Line, d.Subject.Start.Column, d.Summary)
} else if d.Context != nil {
return fmt.Sprintf("%v:%v:%v: %s", d.Context.Filename, d.Context.Start.Line, d.Context.End.Line, d.Summary)
} else {
return fmt.Sprintf("%v", d.Summary)
}
return fmt.Sprintf("%v", d.Summary)
}

func requireNoErrors(t *testing.T, tmpl *ast.TemplateDecl, diags syntax.Diagnostics) {
Expand Down

0 comments on commit 93c9904

Please sign in to comment.