Skip to content
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
1 change: 1 addition & 0 deletions .github/workflows/weekly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
private_key: ${{ secrets.TRUNK_OPEN_PR_APP_PRIVATE_KEY }}

- name: Trunk Upgrade
id: upgrade
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Revert? Assuming you used this for the test run.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Leaving in. Doesn't detract, and makes future debugging easier

uses: ./upgrade # external users: use trunk-io/trunk-action/upgrade@v1
with:
github-token: ${{ steps.generate-token.outputs.token }}
Expand Down
30 changes: 29 additions & 1 deletion upgrade/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,15 @@ inputs:
required: false
default: "false"

branch-name:
description: The branch name to generate the PR from
default: trunk-io/update-trunk
required: false

assignees:
description: A comma or newline separated list of GitHub assignee usernames
required: false

reviewers:
description: A comma or newline separated list of GitHub reviewer usernames
required: false
Expand All @@ -61,6 +70,23 @@ inputs:
description: A boolean to add a Signed-off-by line to the commit message
required: false
default: false
outputs:
pull-request-number:
description: The pull request number
value: ${{ steps.cpr.outputs.pull-request-number }}

pull-request-url:
description: The URL of the pull request.
value: ${{ steps.cpr.outputs.pull-request-url }}

pull-request-operation:
description:
The pull request operation performed by the action, `created`, `updated` or `closed`.
value: ${{ steps.cpr.outputs.pull-request-operation }}

pull-request-head-sha:
description: The commit SHA of the pull request branch.
value: ${{ steps.cpr.outputs.pull-request-head-sha }}

runs:
using: composite
Expand Down Expand Up @@ -115,16 +141,18 @@ runs:
${{ github.action_path }}/../cleanup.sh

- name: Create Pull Request
id: cpr
uses: peter-evans/create-pull-request@v6
with:
title: ${{ inputs.prefix }}${{ env.PR_TITLE }}
body: ${{ env.PR_DESCRIPTION }}
base: ${{ inputs.base }}
branch: trunk-io/update-trunk
branch: ${{ inputs.branch-name }}
labels: trunk
add-paths: ${{ inputs.add-paths }}
commit-message: ${{ inputs.prefix }}${{ env.PR_TITLE }}
delete-branch: true
assignees: ${{ inputs.assignees }}
reviewers: ${{ inputs.reviewers }}
token: ${{ inputs.github-token }}
signoff: ${{ inputs.signoff }}