11# ` @nexB/scancode-action `
22
3- Run [ ScanCode.io] ( https://github.com/aboutcode-org/scancode.io ) pipelines from
4- your Workflows.
5-
6- > [ !IMPORTANT] The scancode-action is currently in the ** alpha stage** , and we
7- > invite you to contribute to its improvement. Please feel free to submit bug
8- > reports or share your ideas by creating new entries in the "Issues" section.
9- > Your collaboration helps us enhance the action and ensures a more stable and
10- > effective tool for the community. Thank you for your support!
11-
12- - [ Usage] ( #usage )
13- - [ Basic] ( #basic )
14- - [ Inputs] ( #inputs )
15- - [ Examples] ( #examples )
16- - [ Scan repo codebase] ( #scan-repo-codebase )
17- - [ Run a specific pipeline] ( #run-a-specific-pipeline )
18- - [ Run multiple pipelines] ( #run-multiple-pipelines )
19- - [ Choose the output formats] ( #choose-the-output-formats )
20- - [ Provide download URLs inputs] ( #provide-download-urls-inputs )
21- - [ Fetch pipelines inputs] ( #fetch-pipelines-inputs )
22- - [ Define a custom project name] ( #define-a-custom-project-name )
23- - [ Where does the scan results go?] ( #where-does-the-scan-results-go )
3+ Run [ ScanCode.io] ( https://github.com/nexB/scancode.io ) pipelines from your Workflows.
4+
5+ > [ !IMPORTANT]
6+ > The scancode-action is currently in the ** alpha stage** , and we invite you to
7+ > contribute to its improvement. Please feel free to submit bug reports or share
8+ > your ideas by creating new entries in the "Issues" section.
9+ > Your collaboration helps us enhance the action and ensures a more stable and
10+ > effective tool for the community.
11+ > Thank you for your support!
12+
13+ - [ Usage] ( #usage )
14+ - [ Basic] ( #basic )
15+ - [ Inputs] ( #inputs )
16+ - [ Examples] ( #examples )
17+ - [ Scan repo codebase] ( #scan-repo-codebase )
18+ - [ Run a specific pipeline] ( #run-a-specific-pipeline )
19+ - [ Run multiple pipelines] ( #run-multiple-pipelines )
20+ - [ Choose the output formats] ( #choose-the-output-formats )
21+ - [ Provide download URLs inputs] ( #provide-download-urls-inputs )
22+ - [ Fetch pipelines inputs] ( #fetch-pipelines-inputs )
23+ - [ Define a custom project name] ( #define-a-custom-project-name )
24+ - [ Where does the scan results go?] ( #where-does-the-scan-results-go )
2425
2526## Usage
2627
2728### Basic
2829
2930``` yaml
3031steps :
31- - uses : actions/checkout@v4
32- with :
33- path : scancode-inputs
34- - uses : nexB/scancode-action@alpha
35- with :
36- pipelines : ' scan_codebase'
37- output-formats : ' json xlsx spdx cyclonedx'
32+ - uses : actions/checkout@v4
33+ with :
34+ path : scancode-inputs
35+ - uses : nexB/scancode-action@alpha
36+ with :
37+ pipelines : " scan_codebase"
38+ output-formats : " json xlsx spdx cyclonedx"
3839` ` `
3940
4041### Inputs
4142
4243` ` ` yaml
4344- uses : nexB/scancode-action@alpha
4445 with :
45- # Names of the pipelines (comma-separated) and in order.
46- # Default is 'scan_codebase'
47- pipelines :
46+ # Names of the pipelines (comma-separated) and in order.
47+ # Default is 'scan_codebase'
48+ pipelines :
4849
49- # The list of output formats to generate.
50- # Default is 'json xlsx spdx cyclonedx'
51- output-formats :
50+ # The list of output formats to generate.
51+ # Default is 'json xlsx spdx cyclonedx'
52+ output-formats :
5253
53- # Relative path within the $GITHUB_WORKSPACE for pipeline inputs.
54- # Default is 'scancode-inputs'
55- inputs-path :
54+ # Relative path within the $GITHUB_WORKSPACE for pipeline inputs.
55+ # Default is 'scancode-inputs'
56+ inputs-path :
5657
57- # Provide one or more URLs to download for the pipeline run execution
58- input-urls :
58+ # Provide one or more URLs to download for the pipeline run execution
59+ input-urls :
5960
60- # Name of the project.
61- # Default is 'scancode-action'
62- project-name :
61+ # Name of the project.
62+ # Default is 'scancode-action'
63+ project-name :
6364
64- # Name of the outputs archive.
65- # Default is 'scancode-outputs'
66- outputs-archive-name :
65+ # Name of the outputs archive.
66+ # Default is 'scancode-outputs'
67+ outputs-archive-name :
6768
68- # Python version that will be installed to run ScanCode.io
69- # Default is '3.11'
70- python-version :
69+ # Python version that will be installed to run ScanCode.io
70+ # Default is '3.11'
71+ python-version :
7172` ` `
7273
7374## Examples
7475
75- See https://github.com/aboutcode-org /scancode-action/tree/main/.github/workflows
76- for Workflows examples.
76+ See https://github.com/nexB /scancode-action/tree/main/.github/workflows for Workflows
77+ examples.
7778
7879### Scan repo codebase
7980
8081` ` ` yaml
8182steps :
82- - uses : actions/checkout@v4
83- with :
84- path : scancode-inputs
85- - uses : nexB/scancode-action@alpha
83+ - uses : actions/checkout@v4
84+ with :
85+ path : scancode-inputs
86+ - uses : nexB/scancode-action@alpha
8687` ` `
8788
8889### Run a specific pipeline
@@ -92,70 +93,70 @@ steps:
9293` ` ` yaml
9394- uses : nexB/scancode-action@alpha
9495 with :
95- pipelines : ' scan_codebase'
96+ pipelines : " scan_codebase"
9697` ` `
9798
9899### Run multiple pipelines
99100
100101` ` ` yaml
101102- uses : nexB/scancode-action@alpha
102103 with :
103- pipelines : ' scan_codebase,find_vulnerabilities'
104+ pipelines : " scan_codebase,find_vulnerabilities"
104105 env :
105- VULNERABLECODE_URL : https://public.vulnerablecode.io/
106+ VULNERABLECODE_URL : https://public.vulnerablecode.io/
106107` ` `
107108
108109#### Configuring ` find_vulnerabilities` Pipeline
109110
110- The `find_vulnerabilities` pipeline requires access to a VulnerableCode
111- instance, which can be defined using the `VULNERABLECODE_URL` environment
112- variable.
111+ The `find_vulnerabilities` pipeline requires access to a VulnerableCode instance,
112+ which can be defined using the `VULNERABLECODE_URL` environment variable.
113113
114- In the example provided, a public instance is referenced. However, you also have
115- the option to run your own VulnerableCode instance. For details on setting up
116- and configuring your own instance, please refer to the
114+ In the example provided, a public instance is referenced.
115+ However, you also have the option to run your own VulnerableCode instance.
116+ For details on setting up and configuring your own instance, please refer to the
117117[VulnerableCode documentation](https://vulnerablecode.readthedocs.io/en/latest/index.html).
118118
119119# ## Choose the output formats
120120
121121` ` ` yaml
122122- uses: nexB/scancode-action@alpha
123123 with:
124- output-formats: ' json xlsx spdx cyclonedx'
124+ output-formats: " json xlsx spdx cyclonedx"
125125` ` `
126126
127127# ## Provide download URLs inputs
128128
129129` ` ` yaml
130130- uses: nexB/scancode-action@alpha
131131 with:
132- pipelines: 'map_deploy_to_develop'
133- input-urls:
134- https://domain.url/source.zip#from https://domain.url/binaries.zip#to
132+ pipelines: "map_deploy_to_develop"
133+ input-urls:
134+ https://domain.url/source.zip#from
135+ https://domain.url/binaries.zip#to
135136` ` `
136137
137138# ## Fetch pipelines inputs
138139
139140` ` ` yaml
140141- name: Download repository archive to scancode-inputs/ directory
141142 run: |
142- wget --directory-prefix=scancode-inputs https://github.com/${GITHUB_REPOSITORY}/archive/${GITHUB_REF}.zip
143+ wget --directory-prefix=scancode-inputs https://github.com/${GITHUB_REPOSITORY}/archive/${GITHUB_REF}.zip
143144- uses: nexB/scancode-action@alpha
144145 with:
145- pipelines: ' scan_single_package'
146+ pipelines: " scan_single_package"
146147` ` `
147148
148149# ## Define a custom project name
149150
150151` ` ` yaml
151152- uses: nexB/scancode-action@alpha
152153 with:
153- project-name: ' my-project-name'
154+ project-name: " my-project-name"
154155` ` `
155156
156157# # Where are the Scan Results?
157158
158- Upon completion of the workflow, you can **find the scan results** in the
159- dedicated **artifacts section** at the bottom of the workflow summary page. Look
160- for a file named `scancode-outputs` in that section. This file contains the
161- outputs generated by the `scancode-action`.
159+ Upon completion of the workflow, you can **find the scan results** in the dedicated
160+ **artifacts section** at the bottom of the workflow summary page.
161+ Look for a file named `scancode-outputs` in that section.
162+ This file contains the outputs generated by the `scancode-action`.
0 commit comments