Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mention new "OWNER:REPO:BRANCH" pattern in "Comparing across forks" #34381

Open
1 task done
muzimuzhi opened this issue Aug 22, 2024 · 3 comments
Open
1 task done

Mention new "OWNER:REPO:BRANCH" pattern in "Comparing across forks" #34381

muzimuzhi opened this issue Aug 22, 2024 · 3 comments
Labels
content This issue or pull request belongs to the Docs Content team needs SME This proposal needs review from a subject matter expert pull requests Content related to pull requests waiting for review Issue/PR is waiting for a writer's review

Comments

@muzimuzhi
Copy link
Contributor

muzimuzhi commented Aug 22, 2024

Code of Conduct

What article on docs.github.com is affected?

https://docs.github.com/en/pull-requests/committing-changes-to-your-project/viewing-and-comparing-commits/comparing-commits#comparing-across-forks

What part(s) of the article would you like to see updated?

The section Comparing across forks only mentions the OWNER:BRANCH pattern to specify a compare branch in a three-dot comparison, but recently GitHub started using a new OWNER:REPO:BRANCH pattern.

To compare branches on different repositories, preface the branch names with user names. For example, by specifying octocat:main for base and octo-org:main for compare, you can compare the main branch of the repositories respectively owned by octocat and octo-org.

Here's an example of a comparison between two repositories.

The new pattern can be found in the URL of "Open pull request" pages. Such pages can be opened by visiting https://github.com/OWNER/REPO/pull/new/BRANCH or by clicking the "Open pull request" button in the page of a branch ahead of upstream default branch.

For example,

Additional information

The old form OWNER:BRANCH still works, though I don't know which one is preferable by the GitHub.

For example, https://github.com/github/docs/compare/main...muzimuzhi:gh34381-update-basehead-form?expand=1 still works.

@muzimuzhi muzimuzhi added the content This issue or pull request belongs to the Docs Content team label Aug 22, 2024
@github-actions github-actions bot added the triage Do not begin working on this issue until triaged by the team label Aug 22, 2024
@muzimuzhi muzimuzhi changed the title Mention new "OWNER:REPO:BRANCH" form in "Comparing across forks" Mention new "OWNER:REPO:BRANCH" pattern in "Comparing across forks" Aug 22, 2024
@nguyenalex836 nguyenalex836 added waiting for review Issue/PR is waiting for a writer's review pull requests Content related to pull requests and removed triage Do not begin working on this issue until triaged by the team labels Aug 22, 2024
@nguyenalex836
Copy link
Contributor

@muzimuzhi Thank you for opening an issue! I'll get this triaged for review ✨

@muzimuzhi
Copy link
Contributor Author

muzimuzhi commented Aug 22, 2024

The corresponding API docs may need a similar update, for example the doc of basehead path parameter of REST API endpoint for "Compare to commits".

Not sure if there are any similar GraphQL APIs.

@nguyenalex836 nguyenalex836 added the needs SME This proposal needs review from a subject matter expert label Sep 6, 2024
Copy link
Contributor

github-actions bot commented Sep 6, 2024

Thanks for opening an issue! We've triaged this issue for technical review by a subject matter expert 👀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content This issue or pull request belongs to the Docs Content team needs SME This proposal needs review from a subject matter expert pull requests Content related to pull requests waiting for review Issue/PR is waiting for a writer's review
Projects
None yet
Development

No branches or pull requests

2 participants