Stacked pull requests, issue links and issues in other projects
Four changes to how cards find their merge requests and their linked issues.
Stacked pull requests link on GitHub. GitHub only links a pull request to
the issue it closes when the PR targets the default branch. Stack a second PR
on the first and GitHub shows no link, so the card showed no PR either.
GitGumbo now reads the closing keywords in the PR's title and description
itself: close, closes, closed, fix, fixes, fixed, resolve,
resolves or resolved, before #12 or a link to an issue in the same
repository. Whatever GitHub links is kept; this adds to it. A bare #12 with
no keyword still doesn't link, and neither does an issue in another repository.
GitLab MRs can close an issue by its URL. "Closes https://gitlab.com/group/project/-/issues/42" now links the MR to #42 on the card, the same as "Closes #42", as long as the URL points into the MR's own project. GitLab treats the two the same; now we do too. If your firm has turned on Bare mentions, a same-project issue URL counts as a mention as well.
Keywords inside code don't count. A Fixes #12 inside a fenced or
indented code block, or in inline code, no longer links the MR, on either
provider. That is how GitHub reads a pull request, and we checked it against
GitHub before changing ours. A keyword in a quoted line (> Fixes #12) still
links, because GitHub links those. On GitLab, where GitGumbo is the only thing
reading these keywords, an MR whose only keyword sat in code drops off the card
at its next sync.
Linked issues in other projects are named when you can read them. Until now a blocking or relates-to link into another project was listed as "Issue in another project", with no title and no link, because the board couldn't tell whether you may see it. Now, if that project is also monitored in the firm you're working in and your own access there lets you read the issue, the row shows its title, reference and a link, with In another project for its location. The check uses your access, not the account that syncs the board, so two members of the same firm can see the same row differently. Anyone else still sees "Issue in another project".