You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Show base branch in PR list when different than master #103
I am not sure how hard this is if even possible, but I would really like to have it.
So to reiterate I want the PR list to show a PR is made towards a base branch which is different than the default branch (usually master).
This is not so useful when all PRs are against master, but when some of them are against another branch in many cases towards another open PR it is very useful to see this from the PR list.
Reacted by Brandon Lee, Sindre Sorhus, Jeroen van Warmerdam and Safwan Shaheer
👍 on this suggestion, but I don't know how to find the base branch except on the PR page. Wouldn't exactly want to get every page to parse out a single word...
The tricky part is, to make sure that we get all the PRs on the page in 1 request, we would need to match the filtering settings on the page to be included in our API request. However, more filtering options are exposed in the UI than in the API 😆.
Edit: Yeahhhh, probably not going to work out well that way 😞
The "List Pull Requests" API endpoint will return the base branch for a list of PRs.
This requires authentication...
The tricky part is, to make sure that we get all the PRs on the page in 1 request, we would need to match the filtering settings on the page to be included in our API request. However, more filtering options are exposed in the UI than in the API 😆.
That seems super complex anyway.
The simplest "single request" I can think of is grabbing and parsing each PRs page. But that's 1 request per PR so probably too many to make feasible.
I believe you get a limited # of API requests from an I.P. without auth (can be verified by making an API call from the console in the browser). This is what OctoTree uses to get file info in the tree.
But I agree, it's super complex and isn't going to be very accurate.
I'll keep my eyes peeled for an easier way, but this one may just not be possible to do reasonably.
Is this needed in the main list or would #455 suffice? After #1115 we know what the default branch is for each repo (although we're currently only saving it in sessionStorage)
Activity
sindresorhus commentedon Mar 29, 2016
👍 I could see this being useful for many larger projects.
paulmolluzzo commentedon Apr 3, 2016
👍 on this suggestion, but I don't know how to find the base branch except on the PR page. Wouldn't exactly want to
getevery page to parse out a single word...DrewML commentedon Apr 4, 2016
I think we might be able to pull this off with 1 HTTP request, but it might be a bit funky.
The "List Pull Requests" API endpoint will return the base branch for a list of PRs.
The tricky part is, to make sure that we get all the PRs on the page in 1 request, we would need to match the filtering settings on the page to be included in our API request. However, more filtering options are exposed in the UI than in the API 😆.
Edit: Yeahhhh, probably not going to work out well that way 😞
paulmolluzzo commentedon Apr 4, 2016
This requires authentication...
That seems super complex anyway.
The simplest "single request" I can think of is grabbing and parsing each PRs page. But that's 1 request per PR so probably too many to make feasible.
DrewML commentedon Apr 4, 2016
I believe you get a limited # of API requests from an I.P. without auth (can be verified by making an API call from the console in the browser). This is what
OctoTreeuses to get file info in the tree.But I agree, it's super complex and isn't going to be very accurate.
I'll keep my eyes peeled for an easier way, but this one may just not be possible to do reasonably.
paulmolluzzo commentedon Apr 4, 2016
Everything private is behind user auth.
DrewML commentedon Apr 4, 2016
Ah yeah - forgot for a minute that people use this on Private repositories 😆
fregante commentedon Apr 6, 2018
Is this needed in the main list or would #455 suffice? After #1115 we know what the default branch is for each repo (although we're currently only saving it in
sessionStorage)sindresorhus commentedon Nov 7, 2018
@bfred-it This is for the main list, and #455 was never merged.