Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Aiva2/CCM-6405 template repo sync fixes #38

Merged
merged 6 commits into from
Sep 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions .github/workflows/scheduled-repository-template-sync.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,21 @@ jobs:

steps:
- name: Check out the repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Check out external repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: nhsdigital/nhs-notify-repository-template
repository: NHSDigital/nhs-notify-repository-template
path: nhs-notify-repository-template
token: ${{ github.token }}

- name: Run syncronisation script
run: |
/scripts/githooks/sync-template-repo.sh
./scripts/githooks/sync-template-repo.sh

- name: Create Pull Request
if: ${{ !env.ACT }}
uses: peter-evans/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -40,15 +42,12 @@ jobs:
# Resultant drift from repository template

## Who should respond to this PR?
The team which owns the responsibility for the services the repository maintains
The team which owns the responsibility for this component repository. You may want to consult other contributors.

## How to progress this PR
The repositories guardians should review the contents of the PR and decide
how to proceed, you may wish to back-out certain changes or accept them from the upstream
`nhsdigital/nhs-notify-repository-template` repository.
The repositories guardians should review the contents of the PR and decide how to proceed, you may wish to back-out certain changes or accept them from the upstream `nhsdigital/nhs-notify-repository-template` repository.

If there are changes you do not wish to see again, it is recommended you add exclusions to
`scripts/config/.repository-template-sync-ignore`
If there are changes you do not wish to see again, it is recommended you add exclusions to `scripts/config/.repository-template-sync-ignore`.
labels: |
template
automation
Expand Down
2 changes: 2 additions & 0 deletions scripts/config/.repository-template-sync-ignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Files and folders to ignore when syncing nhs-notify-repository-template back in to this repository
scripts/config/.repository-template-sync-ignore
.github/workflows/
nhs-notify-repository-template/

# Files and Folders in this repository to ignore
.vscode/
Expand Down
2 changes: 1 addition & 1 deletion scripts/githooks/sync-template-repo.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ is_ignored() {
fi

for ignored in "${IGNORED_PATHS[@]}"; do
if [[ "$file" =~ $ignored ]]; then
if [[ -n "$ignored" && "$file" =~ $ignored ]]; then
return 0
fi
done
Expand Down
Loading