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

Propagate removal of old templates #20

Merged
merged 5 commits into from
Feb 9, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/cran-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ body:
git push origin release-candidate-vX.Y.Z`
```


#### Test the release
- [ ] Execute the manual tests on Shiny apps that are deployed on various hosting providers (Posit connect and shinyapps.io) - track the results in GitHub issue (Applicable only for frameworks that use Shiny).
- [ ] Monitor integration tests, if integration fails, create priority issues on the board.
Expand Down
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ body:
git push origin release-candidate-vX.Y.Z
```


#### Test the release
- [ ] Execute the manual tests on Shiny apps that are deployed on various hosting providers (Posit connect and shinyapps.io) - track the results in GitHub issue (Applicable only for frameworks that use Shiny).
- [ ] Monitor integration tests, if integration fails, create priority issues on the board.
Expand Down
127 changes: 69 additions & 58 deletions .github/workflows/propagate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ name: Propagate release templates
# All these PRs will get automatically merged.

on:
push:
# TODO change this to push
pull_request:
branches:
- main
paths:
Expand Down Expand Up @@ -40,62 +41,65 @@ jobs:
# <username-1>
# <username-2>
# ...
- name: teal.logger
- name: gexodus
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: tern.mmrm
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: osprey
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
- name: goshawk
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
- name: tern
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: random.cdisc.data
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
- name: teal.transform
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: rlistings
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: dunlin
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: teal.modules.clinical
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: teal.widgets
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: scda.2022
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
- name: tern.rbmi
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
- name: tern.gee
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: formatters
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: chevron
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: teal.osprey
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
- name: teal.reporter
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: nestcolor
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: teal.code
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: rtables
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: teal.goshawk
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
- name: teal.slice
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: teal.data
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: teal.modules.general
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: scda
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
- name: teal
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
- name: cards
files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'

# - name: teal.logger
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: tern.mmrm
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: osprey
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
# - name: goshawk
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
# - name: tern
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: random.cdisc.data
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
# - name: teal.transform
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: rlistings
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: dunlin
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: teal.modules.clinical
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: teal.widgets
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: scda.2022
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
# - name: tern.rbmi
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
# - name: tern.gee
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: formatters
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: chevron
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: teal.osprey
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
# - name: teal.reporter
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: nestcolor
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: teal.code
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: rtables
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: teal.goshawk
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
# - name: teal.slice
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: teal.data
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: teal.modules.general
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: scda
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'
# - name: teal
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml'
# - name: cards
# files-to-propagate: '.github/ISSUE_TEMPLATE/release.yml'

steps:
- name: Normalize variables
Expand Down Expand Up @@ -144,18 +148,25 @@ jobs:
echo "Copying origin-repo/$name to destination-repo/$name"
cp origin-repo/$name destination-repo/$name
done
rm destination-repo/.github/ISSUE_TEMPLATE/release.yaml destination-repo/.github/ISSUE_TEMPLATE/cran-release.yaml
walkowif marked this conversation as resolved.
Show resolved Hide resolved

- name: Commit and push changes
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: '[skip ci] Propagate files from ${{ github.repository }}'
file_pattern: ${{ matrix.repos.files-to-propagate }}
# TODO restore this pattern
# file_pattern: ${{ matrix.repos.files-to-propagate }}
file_pattern: '.github/ISSUE_TEMPLATE/release.yml .github/ISSUE_TEMPLATE/cran-release.yml .github/ISSUE_TEMPLATE/release.yaml .github/ISSUE_TEMPLATE/cran-release.yaml'
repository: destination-repo
commit_user_name: github-actions
commit_user_email: 41898282+github-actions[bot]@users.noreply.github.com
branch: ${{ env.PR_BRANCH_NAME }}@${{ env.target_branch }}
create_branch: true

- name: Sleep to avoid rate limiting
run: sleep $((RANDOM % 20))
walkowif marked this conversation as resolved.
Show resolved Hide resolved
shell: bash

- name: Create and merge PR in ${{ matrix.repos.name }} repository
uses: actions/github-script@v7
with:
Expand Down Expand Up @@ -183,7 +194,7 @@ jobs:
if (create_new_pr) {
console.log("Creating a new PR");
const result2 = await github.rest.pulls.create({
title: 'Propagate files from ${{ github.repository }}',
title: '[skip actions] Propagate files from ${{ github.repository }}',
owner: repo_owner,
repo: repo_name,
head: '${{ env.PR_BRANCH_NAME }}@${{ env.target_branch }}',
Expand Down