Skip to content

Commit

Permalink
Disable deployment jobs in forked repository (#4528)
Browse files Browse the repository at this point in the history
* Disable deploy-website job in forked repository

* Check repo on deploy-snapshot job
  • Loading branch information
Goooler committed Jan 26, 2022
1 parent 3c12be9 commit e1dc93e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/deploy-snapshot.yaml
Expand Up @@ -8,7 +8,7 @@ on:
jobs:
gradle:
runs-on: ubuntu-latest
if: ${{ !contains(github.event.head_commit.message, 'ci skip') }}
if: github.repository == 'detekt/detekt' && !contains(github.event.head_commit.message, 'ci skip')
steps:
- name: Checkout Repo
uses: actions/checkout@v2
Expand All @@ -31,4 +31,3 @@ jobs:
MAVEN_CENTRAL_PW: ${{ secrets.MAVEN_CENTRAL_PW }}
with:
arguments: publishAllPublicationsToSonatypeSnapshotRepository -Dsnapshot=true --stacktrace
if: ${{ github.repository == 'detekt/detekt'}}
1 change: 1 addition & 0 deletions .github/workflows/deploy-website.yaml
Expand Up @@ -7,6 +7,7 @@ on:

jobs:
build-detekt-docs:
if: github.repository == 'detekt/detekt'
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
Expand Down

0 comments on commit e1dc93e

Please sign in to comment.