Lustrumstek - Verplaats CMS content en bestanden opgeslagen op de server naar de repository #1880
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
# Trigger analysis when pushing in master or pull requests, and when creating | |
# a pull request. | |
push: | |
branches: | |
- master | |
pull_request: | |
types: [opened, synchronize, reopened] | |
name: Sonarcloud analyse | |
jobs: | |
sonarcloud: | |
runs-on: ubuntu-latest | |
# Deze workflow gebruikt een geheime key: SONAR_TOKEN en kan niet van een fork gerund worden | |
# Zie https://jira.sonarsource.com/browse/MMF-1371 | |
if: github.repository == 'csrdelft/csrdelft.nl' | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
# Disabling shallow clone is recommended for improving relevancy of reporting | |
fetch-depth: 0 | |
- name: Cache Yarn packages | |
id: yarn-cache | |
uses: actions/cache@v3 | |
with: | |
path: | | |
.yarn | |
.pnp.cjs | |
.pnp.loader.mjs | |
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock', '.yarnrc.yml') }} | |
restore-keys: | | |
${{ runner.os }}-yarn- | |
- name: Install yarn dependencies | |
if: steps.yarn-cache.outputs.cache-hit != 'true' | |
run: yarn install --immutable | |
- name: ESLint report | |
run: yarn run lint -f json-relative -o eslint-result.json | |
continue-on-error: true | |
- name: SonarCloud Scan | |
if: env.SONAR_TOKEN != '' | |
uses: sonarsource/sonarcloud-github-action@master | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} |