Skip to content

feat: [draft] add experimental npm sigstore-tuf suport #6

feat: [draft] add experimental npm sigstore-tuf suport

feat: [draft] add experimental npm sigstore-tuf suport #6

name: Pre submits Lint
on: [pull_request]
permissions:
# Needed to check out the repo.
contents: read
jobs:
golangci-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4.1.0
with:
go-version-file: "go.mod"
- env:
GOLANGCI_LINT_VERSION: "1.53.2"
GOLANGCI_LINT_CHECKSUM: "2298f73b9bc03b88b91fee06c5d519fc7f9d7f328e2c388615bbd7e85a9d6cae"
run: |
set -euo pipefail
#Install golangci-lint
curl -sSLo golangci-lint.tar.gz "https://github.com/golangci/golangci-lint/releases/download/v${GOLANGCI_LINT_VERSION}/golangci-lint-${GOLANGCI_LINT_VERSION}-linux-amd64.tar.gz"
echo "golangci-lint checksum is $(sha256sum golangci-lint.tar.gz | awk '{ print $1 }')"
echo "expected checksum is $GOLANGCI_LINT_CHECKSUM"
echo "$GOLANGCI_LINT_CHECKSUM golangci-lint.tar.gz" | sha256sum --strict --check --status || exit -2
tar xf golangci-lint.tar.gz
mv golangci-lint-${GOLANGCI_LINT_VERSION}-linux-amd64/golangci-lint /usr/local/bin
# Run golangci-lint
make golangci-lint
yamllint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- env:
YAMLLINT_VERSION: "1.26.3"
run: |
set -euo pipefail
# Install yamllint
pip install "yamllint==${YAMLLINT_VERSION}"
# Run yamllint
make yamllint
eslint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- uses: actions/setup-node@v3
with:
node-version: 16
- run: make eslint