5

Is it possible to add/toggle labels on issues based on a commit message ?

I know that writing "fix #xxx" will close the issue, but what if I'd like to apply a label to it instead ? "v3 #xxx" => label the issue #xxx with the already defined label "v3"

...or something simpler, but the idea is to be able to set a label without visiting the issue page.

Cyril Duchon-Doris
  • 12,964
  • 9
  • 77
  • 164
  • Possibly a duplicate of http://stackoverflow.com/questions/1687262/link-to-the-issue-number-on-github-within-a-commit-message – BM5k May 11 '16 at 19:29
  • Oh sorry ! I realize my vocabulary was totally wrong. I don't want to TAG but LABEL the issue with one of the custom labels defined in my repository. – Cyril Duchon-Doris May 11 '16 at 21:46
  • Hmm. I don't think that's possible from a commit message. Would a CLI tool work? There's [hub](http://hub.github.com/). Or you could DIY using the github api. – BM5k May 11 '16 at 22:09
  • This is definitely not a duplicate of http://stackoverflow.com/questions/1687262/link-to-the-issue-number-on-github-within-a-commit-message . This is about labels – chrismarx May 22 '18 at 15:10

1 Answers1

-2

If you comment on the issue with just the issue number, github's markdown gnomes will automagically turn that into a link. Just precede the issue number with the pound sign AKA hash tag.

I.e.

my great commit message

[re #12]

will change the #12 to a link when viewed on github.

BM5k
  • 1,210
  • 10
  • 28