Skip to content

Commit

Permalink
feat(cicd): allow to skip test on workflow dispatch
Browse files Browse the repository at this point in the history
  • Loading branch information
tchiotludo committed Aug 3, 2022
1 parent dc40a61 commit aeb04d3
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,12 @@ on:
repository_dispatch:
types: [rebuild]
workflow_dispatch:

inputs:
skip-test:
description: 'Skip test'
required: false
type: string
default: "false"

jobs:
check:
Expand All @@ -38,6 +43,7 @@ jobs:
# Services
- name: Build the docker-compose stack
run: docker-compose -f docker-compose-ci.yml up -d
if: ${{ github.event.inputs.skip-test == 'false' || github.event.inputs.skip-test == '' }}

# Caches
- name: Gradle cache
Expand Down Expand Up @@ -78,6 +84,7 @@ jobs:

# Gradle check
- name: Build with Gradle
if: ${{ github.event.inputs.skip-test == 'false' || github.event.inputs.skip-test == '' }}
env:
GOOGLE_SERVICE_ACCOUNT: ${{ secrets.GOOGLE_SERVICE_ACCOUNT }}
run: |
Expand All @@ -89,6 +96,7 @@ jobs:
# Codecov
- uses: codecov/codecov-action@v3
if: ${{ github.event.inputs.skip-test == 'false' || github.event.inputs.skip-test == '' }}
with:
token: ${{ secrets.CODECOV_TOKEN }}

Expand Down

0 comments on commit aeb04d3

Please sign in to comment.