Commit graph

5 commits

Author SHA1 Message Date
AliabbasMerchant
864d74d0b1 Categorize Templates as Legacy and NonLegacy 2020-05-23 00:03:38 +05:30
Mislav Marohnić
8b9e7df705 Fix parsing some issue template names
YAML parsing sometimes gets sabotaged by asterisks that follow the end
of frontmatter (`---`). We now scope YAML parsing to only frontmatter
and we don't pass any contents that follow.
2020-05-07 15:50:01 +02:00
Tariq Ibrahim
653229c7b5
simplify sort string slice method call 2020-03-24 22:47:51 -07:00
Mislav Marohnić
d553f45bd1 Replace goto with break <label>
Labels are neat, but let's not use them for control flow just yet unless
it REALLY improves on any other alternative.
2019-12-20 15:05:37 +01:00
Mislav Marohnić
d5ba3de751 Add template support to issue create, pr create
If multiple templates are found, the user is prompted to select one.

The templates are searched for, in order of preference:

- issues:
  1. `.github/ISSUE_TEMPLATE/*.md`
  2. `.github/ISSUE_TEMPLATE.md`
  3. `ISSUE_TEMPLATE/*.md`
  4. `ISSUE_TEMPLATE.md`
  5. `docs/ISSUE_TEMPLATE/*.md`
  6. `docs/ISSUE_TEMPLATE.md`

- pull requests:
  1. `.github/PULL_REQUEST_TEMPLATE/*.md`
  2. `.github/PULL_REQUEST_TEMPLATE.md`
  3. `PULL_REQUEST_TEMPLATE/*.md`
  4. `PULL_REQUEST_TEMPLATE.md`
  5. `docs/PULL_REQUEST_TEMPLATE/*.md`
  6. `docs/PULL_REQUEST_TEMPLATE.md`

The filename matches are case-insensitive.
2019-12-18 22:15:20 +01:00