[PR #6622] [MERGED] Restrict AI-generated release notes workflow to PRs targeting master branch #55938

Closed
opened 2026-05-01 03:21:43 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/actualbudget/actual/pull/6622
Author: @Copilot
Created: 1/11/2026
Status: Merged
Merged: 1/13/2026
Merged by: @MatissJanis

Base: masterHead: copilot/update-release-notes-trigger


📝 Commits (4)

  • 8c194c6 Initial plan
  • 0e39b74 Add release notes for PR #6622
  • aa483c8 Update release-notes workflow to only trigger for PRs against master
  • 11006cb Fix: Apply branch filter to AI release notes workflow instead of check workflow

📊 Changes

3 files changed (+22 additions, -1 deletions)

View changed files

📝 .github/actions/ai-generated-release-notes/pr-details.js (+2 -0)
📝 .github/workflows/ai-generated-release-notes.yml (+14 -1)
upcoming-release-notes/6622.md (+6 -0)

📄 Description

The AI-generated release notes workflow currently triggers for all PRs regardless of target branch. This causes unnecessary runs for PRs targeting release branches, feature branches, or other non-master branches.

Changes

  • Modified .github/actions/ai-generated-release-notes/pr-details.js to include the base branch (baseBranch) in its output
  • Added a new step "Check if PR targets master branch" in .github/workflows/ai-generated-release-notes.yml that validates the PR's base branch
  • Updated the condition for subsequent steps to only proceed when targets_master == 'true'
- name: Check if PR targets master branch
  if: steps.check-first-comment.outputs.result == 'true' && steps.pr-details.outputs.result != 'null'
  id: check-base-branch
  run: |
    BASE_BRANCH=$(echo '${{ steps.pr-details.outputs.result }}' | jq -r '.baseBranch')
    echo "Base branch: $BASE_BRANCH"
    if [ "$BASE_BRANCH" = "master" ]; then
      echo "targets_master=true" >> $GITHUB_OUTPUT
    else
      echo "targets_master=false" >> $GITHUB_OUTPUT
      echo "PR does not target master branch, skipping release notes generation"
    fi

The AI-generated release notes workflow now only executes when PRs target master as the base branch, reducing unnecessary API calls and CI overhead for branch-to-branch PRs. The release notes checking workflow (.github/workflows/release-notes.yml) continues to run on all PRs as intended.

Original prompt

This section details on the original issue you should resolve

<issue_title>Auto-generated release notes job should only trigger for PRs against master branch</issue_title>
<issue_description>Currently, the auto-generated release notes job triggers for all PRs regardless of the target branch. This should be updated to only trigger when PRs are opened against the master branch.

Context:

Comments on the Issue (you are @copilot in this section)


Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/actualbudget/actual/pull/6622 **Author:** [@Copilot](https://github.com/apps/copilot-swe-agent) **Created:** 1/11/2026 **Status:** ✅ Merged **Merged:** 1/13/2026 **Merged by:** [@MatissJanis](https://github.com/MatissJanis) **Base:** `master` ← **Head:** `copilot/update-release-notes-trigger` --- ### 📝 Commits (4) - [`8c194c6`](https://github.com/actualbudget/actual/commit/8c194c698f356f13f1ca644da9e0313530759aab) Initial plan - [`0e39b74`](https://github.com/actualbudget/actual/commit/0e39b74a341fbfaf8fccf98ad2b60cbfab67d18e) Add release notes for PR #6622 - [`aa483c8`](https://github.com/actualbudget/actual/commit/aa483c81362255df381ad1c0a5073943550de56d) Update release-notes workflow to only trigger for PRs against master - [`11006cb`](https://github.com/actualbudget/actual/commit/11006cb77ff015fd467e96fa202a05e2461c4b2e) Fix: Apply branch filter to AI release notes workflow instead of check workflow ### 📊 Changes **3 files changed** (+22 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `.github/actions/ai-generated-release-notes/pr-details.js` (+2 -0) 📝 `.github/workflows/ai-generated-release-notes.yml` (+14 -1) ➕ `upcoming-release-notes/6622.md` (+6 -0) </details> ### 📄 Description The AI-generated release notes workflow currently triggers for all PRs regardless of target branch. This causes unnecessary runs for PRs targeting release branches, feature branches, or other non-master branches. ## Changes - Modified `.github/actions/ai-generated-release-notes/pr-details.js` to include the base branch (`baseBranch`) in its output - Added a new step "Check if PR targets master branch" in `.github/workflows/ai-generated-release-notes.yml` that validates the PR's base branch - Updated the condition for subsequent steps to only proceed when `targets_master == 'true'` ```yaml - name: Check if PR targets master branch if: steps.check-first-comment.outputs.result == 'true' && steps.pr-details.outputs.result != 'null' id: check-base-branch run: | BASE_BRANCH=$(echo '${{ steps.pr-details.outputs.result }}' | jq -r '.baseBranch') echo "Base branch: $BASE_BRANCH" if [ "$BASE_BRANCH" = "master" ]; then echo "targets_master=true" >> $GITHUB_OUTPUT else echo "targets_master=false" >> $GITHUB_OUTPUT echo "PR does not target master branch, skipping release notes generation" fi ``` The AI-generated release notes workflow now only executes when PRs target `master` as the base branch, reducing unnecessary API calls and CI overhead for branch-to-branch PRs. The release notes checking workflow (`.github/workflows/release-notes.yml`) continues to run on all PRs as intended. <!-- START COPILOT ORIGINAL PROMPT --> <details> <summary>Original prompt</summary> > > ---- > > *This section details on the original issue you should resolve* > > <issue_title>Auto-generated release notes job should only trigger for PRs against master branch</issue_title> > <issue_description>Currently, the auto-generated release notes job triggers for all PRs regardless of the target branch. This should be updated to only trigger when PRs are opened against the `master` branch. > > **Context:** > - Requested by @MatissJanis in PR actualbudget/actual#6596 > - PR URL: https://github.com/actualbudget/actual/pull/6596</issue_description> > > ## Comments on the Issue (you are @copilot in this section) > > <comments> > </comments> > </details> <!-- START COPILOT CODING AGENT SUFFIX --> - Fixes actualbudget/actual#6597 <!-- START COPILOT CODING AGENT TIPS --> --- ✨ Let Copilot coding agent [set things up for you](https://github.com/actualbudget/actual/issues/new?title=✨+Set+up+Copilot+instructions&body=Configure%20instructions%20for%20this%20repository%20as%20documented%20in%20%5BBest%20practices%20for%20Copilot%20coding%20agent%20in%20your%20repository%5D%28https://gh.io/copilot-coding-agent-tips%29%2E%0A%0A%3COnboard%20this%20repo%3E&assignees=copilot) — coding agent works faster and does higher quality work when set up for your repo. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-05-01 03:21:43 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#55938