Skip to content

feat: refine action for enhanced security #47

feat: refine action for enhanced security

feat: refine action for enhanced security #47

Workflow file for this run

on:
workflow_dispatch:
pull_request:
push:
branches:
- main
jobs:
multi-runs:
runs-on: ubuntu-24.04
permissions:
contents: read
name: Ensure the action can be executed multiple times
steps:
- name: Get the action.yml from the current branch
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
sparse-checkout: action.yml
sparse-checkout-cone-mode: false
persist-credentials: false
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
path: scancode-inputs
persist-credentials: false
- uses: ./
with:
project-name: "scan-1"
pipelines: "scan_codebase"
- uses: ./
with:
project-name: "scan-2"
pipelines: "scan_codebase"
- name: Verify scanpipe and scancode commands availability
shell: bash
run: |
echo "Checking ScanCode CLI availability..."
which scanpipe || { echo "scanpipe not found in PATH"; exit 1; }
which scancode || { echo "scancode not found in PATH"; exit 1; }
echo "Versions:"
scanpipe shell -c "import scancodeio; from scancode_config import __version__ as scancode_version;print(f'ScanCode.io version: {scancodeio.__version__}');print(f'ScanCode-toolkit version: v{scancode_version}')"