From b1cb00842a9af0abc53544774a5b400708b815ee Mon Sep 17 00:00:00 2001 From: Fabrice Bellingard Date: Tue, 13 Aug 2019 09:39:51 +0200 Subject: [PATCH] Update main.workflow sample to use YML syntax --- README.md | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index f3fd437..b756695 100644 --- a/README.md +++ b/README.md @@ -27,15 +27,19 @@ sonar.sources=. The workflow, usually declared in `.github/main.workflow`, looks like: ``` -workflow "Main Workflow" { - on = "push" - resolves = "SonarCloud Trigger" -} - -action "SonarCloud Trigger" { - uses = "sonarsource/sonarcloud-github-action@master" - secrets = ["GITHUB_TOKEN", "SONAR_TOKEN"] -} +on: push +name: Main Workflow +jobs: + sonarCloudTrigger: + name: SonarCloud Trigger + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@master + - name: SonarCloud Scan + uses: sonarsource/sonarcloud-github-action@master + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} ``` ### Secrets