repolens 1.4.0

A CLI tool to audit and prepare repositories for open source or enterprise standards
Documentation
# RepoLens Audit with SARIF Upload
#
# This workflow runs a RepoLens audit and uploads the results in SARIF format
# to GitHub Advanced Security. Findings will appear in the Security tab
# under "Code scanning alerts".
#
# Note: GitHub Advanced Security must be enabled on your repository.
# For public repositories this is free. For private repositories,
# a GitHub Advanced Security license is required.

name: RepoLens Security Scan

on:
  push:
    branches: [main]
  pull_request:
    branches: [main]
  schedule:
    # Run weekly on Mondays at 08:00 UTC
    - cron: '0 8 * * 1'

permissions:
  security-events: write
  contents: read

jobs:
  security-scan:
    name: Security Scan
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v4

      - name: Run RepoLens audit (SARIF)
        id: audit
        uses: systm-d/repolens@main
        with:
          preset: 'enterprise'
          format: 'sarif'
          fail-on: 'none'
          artifact-name: 'repolens-sarif'

      - name: Upload SARIF to GitHub Security
        if: always() && steps.audit.outputs.report-path != ''
        uses: github/codeql-action/upload-sarif@v3
        with:
          sarif_file: ${{ steps.audit.outputs.report-path }}
          category: 'repolens'

      - name: Summary
        if: always()
        run: |
          echo "## RepoLens Security Scan Results" >> $GITHUB_STEP_SUMMARY
          echo "" >> $GITHUB_STEP_SUMMARY
          echo "- **Findings:** ${{ steps.audit.outputs.findings-count }}" >> $GITHUB_STEP_SUMMARY
          echo "- **Exit code:** ${{ steps.audit.outputs.exit-code }}" >> $GITHUB_STEP_SUMMARY
          echo "- **Report:** uploaded as SARIF to GitHub Security tab" >> $GITHUB_STEP_SUMMARY