Skip to content

Commit

Permalink
fix: deprecated workflows tools
Browse files Browse the repository at this point in the history
  • Loading branch information
andreeaneata committed Jul 8, 2024
1 parent 3339095 commit 3a951d5
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 18 deletions.
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ jobs:
iac-scan: disabled
lint_commit_message:
docker:
- image: cimg/node:14.19
- image: cimg/node:18.19.1
steps:
- checkout
- attach_workspace:
Expand Down Expand Up @@ -150,7 +150,7 @@ jobs:
command: echo $DOCKER_PASSWORD | docker login -u $DOCKER_USERNAME --password-stdin
- node/install:
install-yarn: false
node-version: '12'
node-version: '18'
- run:
name: Release binaries to GitHub
command: ./scripts/release-github.sh
Expand Down
2 changes: 1 addition & 1 deletion .github/actions/setup_shellspec/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ runs:
steps:
- uses: actions/setup-node@v1
with:
node-version: 15
node-version: 18

- name: Install Snyk with npm
shell: bash
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/contract.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:

- uses: actions/setup-node@v1
with:
node-version: 15
node-version: 18

- name: Install Snyk with npm
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ jobs:
- name: Build binaries
uses: goreleaser/goreleaser-action@v2
with:
args: --snapshot --rm-dist
args: --snapshot --clean

- name: Test Dockerfile
run: |
Expand Down
27 changes: 17 additions & 10 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# yaml-language-server: $schema=https://goreleaser.com/static/schema.json
# vim: set ts=2 sw=2 tw=0 fo=jcroql
version: 2

project_name: snyk-iac-rules

before:
Expand Down Expand Up @@ -27,13 +31,16 @@ archives:
- id: default
files:
- none*
name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}"
replacements:
darwin: Darwin
linux: Linux
windows: Windows
386: i386
amd64: x86_64
name_template: >-
{{- .ProjectName }}_
{{- .Version }}_
{{- if eq .Os "darwin" }}Darwin
{{- else if eq .Os "linux" }}Linux
{{- else if eq .Os "windows" }}Windows
{{- else }}{{ .Os }}{{ end }}
{{- if eq .Arch "386" }}i386
{{- else if eq .Arch "amd64" }}x86_64
{{- else }}{{ .Arch }}{{ end -}}
format: tar.gz
format_overrides:
- goos: windows
Expand Down Expand Up @@ -83,20 +90,20 @@ brews:
# Default is false.
skip_upload: false
# GitHub repository to push the formula to
tap:
repository:
owner: snyk
name: homebrew-tap
token: "{{ .Env.SNYK_ACCESS_TOKEN }}"

folder: Formula
directory: Formula
commit_author:
name: snyk
email: [email protected]
homepage: "https://snyk.io/"
license: Apache-2.0
description: "Write, debug, test, and bundle custom rules for Snyk Infrastructure as Code."

scoop:
scoops:
# If set to auto, the release will not be uploaded to the scoop bucket
# in case there is an indicator for prerelease in the tag e.g. v1.0.0-rc1
# Default is false.
Expand Down
1 change: 1 addition & 0 deletions packaging/npm/passthrough.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ switch (process.platform) {
var arch = ''
switch (process.arch) {
case 'arm' :
case 'arm64':
arch = 'arm64';
break;
case 'x64':
Expand Down
4 changes: 2 additions & 2 deletions scripts/release-github.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@
set -eo pipefail

if ! which goreleaser >/dev/null ; then
go install github.com/goreleaser/goreleaser@v1.9.2
go install github.com/goreleaser/goreleaser@v2
fi

# Check configuration
goreleaser check

FLAGS=""
FLAGS+="--rm-dist "
FLAGS+="--clean "

# Only CI system should publish artifacts
if [ "$CI" != true ]; then
Expand Down
2 changes: 1 addition & 1 deletion scripts/release-npm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ for i in "$@"; do
done

if ! which goreleaser >/dev/null ; then
go install github.com/goreleaser/goreleaser@v1.9.2
go install github.com/goreleaser/goreleaser@v2
fi

# Check configuration
Expand Down

0 comments on commit 3a951d5

Please sign in to comment.