Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The previous version had a few issues I got bitten by:
it's on gitea/gitlab/github not necessary to have
.git
as suffix for a remote, i.e.is perfectly fine and because I wasn't that, all of my remotes were dismissed by this plugin.
For forked repos I usually adhere to the convention to name my own fork's remote
origin
while the original repo's origin is calledupstream
[1]. This also means that if an issue is referenced in a file, it refers to the upstream's issue tracker.Accordingly I patched this part to prefer the upstream remote over the origin remote (if it exists).
This is just a very bare-bone setup missing a few more important things:
on github at least you can also specify owner#issuename for issues in forks. This is still completely ignored.
the prefer remote X over Y should be at least configurable, perhaps it should be possible to do this on a per-project level.
For me, the current state is good-enough to use and I figured I'd
contribute my changes back here even though the patch is not perfect,
perhaps they're useful as a base to improve this nice plugin.
[1] https://docs.github.com/en/get-started/quickstart/fork-a-repo