Skip to content

Commit

Permalink
Merge pull request #4 from uclahs-cds/nwiltsie-commit-with-different-…
Browse files Browse the repository at this point in the history
…token

Use PAT to open PR to enable workflows to run
  • Loading branch information
nwiltsie authored Aug 9, 2024
2 parents f50f618 + 10825c6 commit 60a1c1c
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 9 deletions.
1 change: 1 addition & 0 deletions .github/workflows/wf-prepare-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ jobs:
- name: Create Pull Request
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.UCLAHS_CDS_REPO_READ_TOKEN }}
path: caller
add-paths: ${{ inputs.changelog }}
commit-message: ${{ steps.bump-changelog.outputs.commit_message }}
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## Unreleased

### Changed

- Pull request is created with separate token so workflows will run

## [0.0.1-rc.1] - 2024-08-05

### Added
Expand Down
9 changes: 0 additions & 9 deletions scripts/finalize-release.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,6 @@ module.exports = async ({ github, context, core }) => {
process.exit()
}

if (
!['Bot', 'Organization'].includes(context.payload.pull_request.user.type)
) {
core.setFailed(
'Workflow should only be called for Bot- or Organization-generated release PRs'
)
process.exit()
}

// This regex needs to kept in-sync with the pattern in create-release-pr.yaml
const regex = /^automation-create-release-(.*)$/i
const parsedVersion = context.payload.pull_request.head.ref.match(regex)
Expand Down

0 comments on commit 60a1c1c

Please sign in to comment.