Skip to content

Commit

Permalink
Update sonarcloud.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
brenoepics authored Jan 31, 2024
1 parent cec7127 commit 8f4d0e9
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion .github/workflows/sonarcloud.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
name: SonarCloud

on:
workflow_dispatch:
inputs:
approval:
description: 'Approve workflow execution'
required: false

push:
branches:
- main
Expand All @@ -10,8 +16,16 @@ on:

pull_request:
types: [opened, synchronize, reopened]

jobs:
approval:
runs-on: ubuntu-latest
steps:
- name: Check if approval is required
run: echo "Approval is required"

build:
needs: approval
name: Build and analyze
runs-on: ubuntu-latest
steps:
Expand Down Expand Up @@ -41,4 +55,4 @@ jobs:
AZURE_KEY: ${{ secrets.AZURE_KEY }}
AZURE_REGION: ${{ secrets.AZURE_REGION }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

0 comments on commit 8f4d0e9

Please sign in to comment.