Skip to content

Commit

Permalink
Use fossa-contrib/fossa-action instead (#2571)
Browse files Browse the repository at this point in the history
* Use fossa-contrib/fossa-action instead

Signed-off-by: Sora Morimoto <[email protected]>

* Make step name clearer

Signed-off-by: Sora Morimoto <[email protected]>

Co-authored-by: Yuri Shkuro <[email protected]>
  • Loading branch information
smorimoto and yurishkuro authored Nov 17, 2020
1 parent 008772e commit f4d6968
Showing 1 changed file with 19 additions and 14 deletions.
33 changes: 19 additions & 14 deletions .github/workflows/fossa.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,25 @@ on:
jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/setup-go@v2
- name: Checkout code
uses: actions/checkout@v2

- name: Use Go ^1.14.x
uses: actions/setup-go@v2
with:
go-version: ^1.14.x

- name: Add GOPATH to GITHUB_ENV
run: echo "GOPATH=$(go env GOPATH)" >>"$GITHUB_ENV"

- name: Add GOPATH to GITHUB_PATH
run: echo "$GOPATH/bin" >>"$GITHUB_PATH"

- name: Run FOSSA scan and upload build data
uses: fossa-contrib/fossa-action@v1
with:
go-version: "^1.14.x"
- run: go version
# Runs a set of commands to initialize and analyze with FOSSA
- name: run FOSSA analysis
env:
# FOSSA Push-Only API Token
FOSSA_API_KEY: '304657e2357ba57b416b94e6b119131b'
run: |
export GOPATH=$HOME/go
export PATH=$PATH:$(go env GOPATH)/bin
curl -H 'Cache-Control: no-cache' https://raw.githubusercontent.com/fossas/fossa-cli/master/install.sh | bash
fossa init
fossa analyze
fossa-api-key: 304657e2357ba57b416b94e6b119131b
github-token: ${{ github.token }}

0 comments on commit f4d6968

Please sign in to comment.