mirror of
https://github.com/sonarsource/sonarcloud-github-action.git
synced 2026-06-08 10:47:13 +00:00
Update main.workflow sample to use YML syntax
This commit is contained in:
parent
cc7ffd578d
commit
b1cb00842a
1 changed files with 13 additions and 9 deletions
22
README.md
22
README.md
|
|
@ -27,15 +27,19 @@ sonar.sources=.
|
||||||
The workflow, usually declared in `.github/main.workflow`, looks like:
|
The workflow, usually declared in `.github/main.workflow`, looks like:
|
||||||
|
|
||||||
```
|
```
|
||||||
workflow "Main Workflow" {
|
on: push
|
||||||
on = "push"
|
name: Main Workflow
|
||||||
resolves = "SonarCloud Trigger"
|
jobs:
|
||||||
}
|
sonarCloudTrigger:
|
||||||
|
name: SonarCloud Trigger
|
||||||
action "SonarCloud Trigger" {
|
runs-on: ubuntu-latest
|
||||||
uses = "sonarsource/sonarcloud-github-action@master"
|
steps:
|
||||||
secrets = ["GITHUB_TOKEN", "SONAR_TOKEN"]
|
- 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
|
### Secrets
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue