Skip to content

Commit bf1b9f1

Browse files
committed
create github actions workflow files for fossa
1 parent 946520a commit bf1b9f1

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

.github/workflows/fossa.yml

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Dependency License Scanning
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
defaults:
9+
run:
10+
shell: bash
11+
12+
jobs:
13+
fossa:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v2
18+
- name: Fossa init
19+
run: |-
20+
curl -H 'Cache-Control: no-cache' https://raw.githubusercontent.com/fossas/fossa-cli/master/install.sh | bash
21+
fossa init
22+
- name: Set env
23+
run: echo ::set-env name=line_number::$(grep -n "project" .fossa.yml | cut -f1 -d:)
24+
- name: Configuration
25+
run: |-
26+
sed -i "${line_number}s|.*| project: [email protected]:${GITHUB_REPOSITORY}.git|" .fossa.yml
27+
cat .fossa.yml
28+
- name: Upload dependencies
29+
run: fossa analyze --debug
30+
env:
31+
FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY }}

0 commit comments

Comments
 (0)