diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 5cd0918..359d812 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -1,26 +1,29 @@ --- name: 🐞 Bug Report -about: Report a bug to help improve Self-Hosted Sentry +about: Report a bug in Self-Hosted Sentry --- -## Version Information +### Version Information Version: *VERSION HERE* +### Steps to Reproduce -## Description +1. What +2. you +3. did. -[What happened] +### Expected Result -## Steps to Reproduce +What you thought would happen. -1. [First Step] -2. [Second Step] -3. and so on. +### Actual Result -## Logs +What actually happened. Maybe a screenshot/recording? -Please share any applicable logs: +### Logs -- `ls -1 sentry_install_log-*.txt | tail -1 | xargs cat` # latest instal logs +What you saw along the way, e.g.: + +- latest install logs: `ls -1 sentry_install_log-*.txt | tail -1 | xargs cat` - `docker-compose logs` output diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index bb8c4ee..32e32f2 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -1,28 +1,18 @@ --- -name: 🧠 Feature request -about: Suggest an idea for this project - +name: 🧠 Feature Request +about: Suggest an idea for improving Self-Hosted Sentry --- - - -## Summary +### Summary One paragraph description of the feature. -## Motivation +### Motivation Why should this be worked on? What problems or use cases does it solve or improve? -## Additional Context +### Additional Context Any other context or screenshots or API request payload/responses that pertain to the feature. diff --git a/.github/workflows/validate-new-issue.yml b/.github/workflows/validate-new-issue.yml new file mode 100644 index 0000000..3252396 --- /dev/null +++ b/.github/workflows/validate-new-issue.yml @@ -0,0 +1,36 @@ +name: Validate new issue +on: + issues: + types: ['opened'] +jobs: + validate-new-issue: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: "Validate issue against templates" + shell: bash + run: | + # Look for a template where the headings match this issue's + echo "${{ github.event.issue.body }}" > issue-body + for template in $(ls .github/ISSUE_TEMPLATE/*.md 2> /dev/null); do + echo -n "$(basename $template)? " + # <() is process substitution - https://superuser.com/a/1060002 + if diff -rub <(grep '^#' $template) <(grep '^#' issue-body) > /dev/null; then + echo "👍 💃" + exit 0 + else + echo "👎" + fi + done + + # Failed to find a match! Close the issue. + echo "${{ github.token }}" | gh auth login --with-token + cat << EOF > comment + {"body": "Sorry, friend. As far as this ol' bot can tell, your issue does not use one of this repo's available issue templates. Please [try again using a template](https://github.com/${{ github.repository }}/issues/new/choose) so that we have the best chance of understanding and addressing your issue. (And if I'm confused, please [let us know](https://github.com/getsentry/.github/issues/new?title=template+enforcer+is+confused&body=${{ github.event.issue.html_url }}). 😬)\n\n----\n\n[![Did you see the memo about this?](https://user-images.githubusercontent.com/134455/104515469-e04a9c80-55c0-11eb-8e15-ffe9c0b8dd7f.gif)](https://www.youtube.com/watch?v=Fy3rjQGc6lA)"} + EOF + + # Might get `gh issue comment` some day - https://github.com/cli/cli/issues/517 + gh api "https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/comments" \ + --method POST \ + --input comment + gh issue close ${{ github.event.issue.number }}