Skip to content

ci: fix the CI for PRs from forked projects (#11) #1

ci: fix the CI for PRs from forked projects (#11)

ci: fix the CI for PRs from forked projects (#11) #1

Workflow file for this run

name: CI
on:
push:
branches:
- main
permissions:
contents: read
jobs:
sonarqube:
name: SonarQube Trigger
runs-on: ubuntu-latest
continue-on-error: true
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
if: ${{ secrets.SONAR_TOKEN != '' }}

Check failure on line 20 in .github/workflows/sonar.yml

View workflow run for this annotation

GitHub Actions / CI

Invalid workflow file

The workflow is not valid. .github/workflows/sonar.yml (Line: 20, Col: 13): Unrecognized named-value: 'secrets'. Located at position 1 within expression: secrets.SONAR_TOKEN != '' .github/workflows/sonar.yml (Line: 27, Col: 13): Unrecognized named-value: 'secrets'. Located at position 1 within expression: secrets.SONAR_TOKEN != ''
with:
# Disabling shallow clone is recommended for improving relevancy of reporting
fetch-depth: 0
- name: SonarQube Scan
uses: sonarsource/sonarqube-scan-action@aecaf43ae57e412bd97d70ef9ce6076e672fe0a9
if: ${{ secrets.SONAR_TOKEN != '' }}
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_HOST_URL: ${{ secrets.SONAR_HOST }}
with:
args: >
-Dsonar.projectKey=${{ secrets.SONAR_PROJECT_KEY }}