Skip to content

Commit

Permalink
chore: use snyk gh action instead
Browse files Browse the repository at this point in the history
  • Loading branch information
mefellows committed Feb 1, 2021
1 parent c29f3b4 commit 754d98c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ jobs:
go-version: ${{ matrix.go-version }}
- name: Checkout code
uses: actions/checkout@v2
- name: Run Snyk to check for vulnerabilities
uses: snyk/actions/golang@master
env:
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
- name: Test
run: make
env:
Expand Down
15 changes: 2 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ TEST?=./...

.DEFAULT_GOAL := ci

ci:: docker deps snyk clean bin test pact goveralls
ci:: docker deps clean bin test pact goveralls

docker:
@echo "--- 🛠 Starting docker"
Expand All @@ -21,7 +21,7 @@ bin:
clean:
rm -rf build output dist examples/v3/pacts

deps: snyk-install
deps:
@echo "--- 🐿 Fetching build dependencies "
go get github.com/axw/gocov/gocov
go get github.com/mattn/goveralls
Expand Down Expand Up @@ -83,17 +83,6 @@ testrace:
updatedeps:
go get -d -v -p 2 ./...

snyk-install:
ifeq (, $(shell which snyk))
npm i snyk
endif

snyk:
# only run on CI, but don't do for PRs because tokens aren't available
@if [ "$$GITHUB_HEAD_REF" = "" -a "$$GITHUB_REF" != "" ]; then\
npx snyk test; \
fi

rust:
cd ~/development/public/pact-reference/rust; \
cargo build; \
Expand Down

0 comments on commit 754d98c

Please sign in to comment.