Skip to content

Add PR number to commit messages when landing, like GitHub does #313

@vmoens

Description

@vmoens

When landing PRs with ghstack land, the commits don't include the PR number in their commit messages. This makes it harder to trace commits back to their original PRs when browsing history.

GitHub automatically appends the PR number when merging (e.g., Fix bug (#123)), which is very useful for understanding the context of changes.

Desired behavior:

# Before landing:
commit abc123
    Fix bug
    
# After ghstack land:
commit def456
    Fix bug (#123)

This would make ghstack-landed commits consistent with GitHub's native merge behavior and improve repository archaeology.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions