abhinav / abhinav/git-spice

branch submit matching: account for local changes

オープン
#496 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
area/git enhancement
主要言語
Go
スター
762
フォーク
72
平均マージ
18時間 24分
マージ済み PR(30日)
28

説明

ref: https://github.com/abhinav/git-spice/issues/491#issuecomment-2500793201

When submitting a branch that doesn't have a PR associated with it,
git-spice attempts to detect previously submitted PRs for the same branch
(either by git-spice or manually).
This matching logic expects the PR's HEAD to be the same as the local branch.
If the PR's HEAD is different, git-spice will assume it's a conflicting branch
name and will generate a new upstream branch name.

This breaks a workflow where you:

- check out a PR submitted elsewhere with git-spice
- make a few changes
- try to use git-spice to submit the PR

The PR's head doesn't match the local HEAD because of the local changes.

A possible improvement here is to check the local HEAD's parents. Perhaps:
if PR's HEAD is reachable from the local HEAD,
*and* there are no other branches in the middle,
then consider it a match.

コントリビューションガイド

コントリビューションガイドを開く

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。