diff --git a/.github/workflows/ci-check.yml b/.github/workflows/ci-check.yml index 4fcc970..aa807c9 100644 --- a/.github/workflows/ci-check.yml +++ b/.github/workflows/ci-check.yml @@ -1,7 +1,6 @@ name: Lint CI workflows on: - workflow_call: push: branches: [main] pull_request: diff --git a/.github/workflows/py-publish.yml b/.github/workflows/py-publish.yml deleted file mode 100644 index fee7540..0000000 --- a/.github/workflows/py-publish.yml +++ /dev/null @@ -1,52 +0,0 @@ -name: Build and publish python package - -on: - workflow_call: - -permissions: - contents: read - id-token: write - attestations: write - -jobs: - publish-to-pypi: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - # use fetch --all for setuptools_scm to work - with: - fetch-depth: 0 - persist-credentials: false - - name: Set up Python - uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0 - with: - python-version: '3.x' - - - name: Install dependencies - run: python -m pip install --upgrade pip twine - - - name: Build wheel - run: python -m pip wheel -w dist --no-deps . - - - name: Check distribution - run: twine check dist/* - - - name: Create attestations - uses: actions/attest-build-provenance@4d101475d8b20a2381f78447822ac1eab6504dd8 # v4.2.2 - with: - subject-path: 'dist/*' - - - name: Publish package (to TestPyPI) - if: startsWith(github.repository, 'cpp-linter') && !startsWith(github.ref, 'refs/tags/') && github.ref == 'refs/heads/main' - env: - TWINE_USERNAME: __token__ - TWINE_PASSWORD: ${{ secrets.TEST_PYPI_TOKEN }} # zizmor: ignore[secrets-outside-env] - run: twine upload --repository testpypi dist/* - - - name: Publish package (to PyPI) - if: startsWith(github.repository, 'cpp-linter') && startsWith(github.ref, 'refs/tags/') - env: - TWINE_USERNAME: __token__ - TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} # zizmor: ignore[secrets-outside-env] - run: twine upload dist/* diff --git a/.github/workflows/snyk-container.yml b/.github/workflows/snyk-container.yml deleted file mode 100644 index d7ecb65..0000000 --- a/.github/workflows/snyk-container.yml +++ /dev/null @@ -1,35 +0,0 @@ -name: Snyk Container - -on: - workflow_call: - inputs: - image: - description: 'Docker image to scan' - default: xianpengshen/clang-tools:all - required: false - type: string - -jobs: - snyk: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - with: - persist-credentials: false - - name: Run Snyk to check Docker image for vulnerabilities - continue-on-error: true - uses: snyk/actions/docker@9adf32b1121593767fc3c057af55b55db032dc04 # v1.0.0 - env: - # In order to use the Snyk Action you will need to have a Snyk API token. - # More details in https://github.com/snyk/actions#getting-your-snyk-token - # or you can sign up for free at https://snyk.io/login - SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }} # zizmor: ignore[secrets-outside-env] - with: - image: ${{ inputs.image }} - args: --severity-threshold=high --file=Dockerfile.all - - - name: Upload result to GitHub Code Scanning - if: hashFiles('snyk.sarif') != '' - uses: github/codeql-action/upload-sarif@9b3254085494b55a0f7c4c2b3d2d52cc712ce370 # v4.39.1 - with: - sarif_file: snyk.sarif