Skip to content

Commit

Permalink
Merge pull request #14 from axif0/organization_check
Browse files Browse the repository at this point in the history
feat: org repo check
  • Loading branch information
andrewtavis authored Dec 16, 2024
2 parents 9fe4310 + cc9dd03 commit d4d6844
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/matrix_dev_sync_reminder.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,24 @@ env:
FIRST_RUN_DATE: "2024-11-13"

jobs:
check-repository:
runs-on: ubuntu-latest
outputs:
is_correct_repo: ${{ steps.check.outputs.is_correct_repo }}
steps:
- name: Check repository
id: check
run: |
if [ "$GITHUB_REPOSITORY" = "scribe-org/Organization" ]; then
echo "is_correct_repo=true" >> "$GITHUB_OUTPUT"
else
echo "is_correct_repo=false" >> "$GITHUB_OUTPUT"
echo "::warning::This workflow should only run in scribe-org/Organization repository."
fi
weekindex:
needs: check-repository
if: needs.check-repository.outputs.is_correct_repo == 'true'
runs-on: ubuntu-latest
outputs:
weekindex: ${{ steps.calculate.outputs.weekindex }}
Expand Down Expand Up @@ -56,6 +73,7 @@ jobs:
runs-on: ubuntu-latest
needs:
- weekindex
- check-repository
steps:
- name: Format EPOCH Time
id: epoch-time
Expand Down

0 comments on commit d4d6844

Please sign in to comment.