Skip to content

Commit 71a62a4

Browse files
Copilotpelikhan
andauthored
Use 'force-push semantics' (plural) in docs and code comments
Agent-Logs-Url: https://github.com/github/gh-aw/sessions/73c62235-cc79-479b-b145-e8529c7c8ee0 Co-authored-by: pelikhan <[email protected]>
1 parent 7ea66be commit 71a62a4

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

actions/setup/js/create_pull_request.cjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,7 @@ async function handleRemoteBranchCollision(branchName, preserveBranchName, optio
466466

467467
if (preserveBranchName) {
468468
// Reuse the existing branch by deleting the remote ref so the subsequent
469-
// push recreates it from the local HEAD (force-push semantic). This is the
469+
// push recreates it from the local HEAD (force-push semantics). This is the
470470
// intended behavior of preserve-branch-name for long-lived reusable
471471
// branches whose previous PR was merged.
472472
const { githubClient, owner, repo } = options;

docs/src/content/docs/reference/safe-outputs-pull-requests.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ The `excluded-files` field accepts a list of glob patterns. Each matching file i
8484

8585
The `preserve-branch-name` field, when set to `true`, omits the random hex salt suffix that is normally appended to the agent-specified branch name. This is useful when the target repository enforces branch naming conventions such as Jira keys in uppercase (e.g., `bugfix/BR-329-red` instead of `bugfix/br-329-red-cde2a954`). Invalid characters are always replaced for security, and casing is always preserved regardless of this setting. Defaults to `false`.
8686

87-
When `preserve-branch-name: true` and the agent-supplied branch name already exists on the remote, the workflow reuses the existing branch by force-deleting the stale remote ref and recreating it from the agent's local HEAD (force-push semantic). This is the intended behavior for long-lived reusable branches whose previous PR was merged. The handler does not silently rename the branch in this case.
87+
When `preserve-branch-name: true` and the agent-supplied branch name already exists on the remote, the workflow reuses the existing branch by force-deleting the stale remote ref and recreating it from the agent's local HEAD (force-push semantics). This is the intended behavior for long-lived reusable branches whose previous PR was merged. The handler does not silently rename the branch in this case.
8888

8989
The `draft` field is a **configuration policy**, not a default. Whatever value is set in the workflow frontmatter is always used — the agent cannot override it at runtime.
9090

0 commit comments

Comments
 (0)