From 0428014284abfd94388952a6d440b4b31b3fd1ce Mon Sep 17 00:00:00 2001 From: smiley Date: Thu, 17 Oct 2024 11:48:28 +0200 Subject: [PATCH] :octocat: foolproof issue templates --- .github/ISSUE_TEMPLATE/01-bug-report.yml | 67 +++++++++++++++++++ .github/ISSUE_TEMPLATE/02-feature-request.yml | 53 +++++++++++++++ .github/ISSUE_TEMPLATE/03-documentation.yml | 40 +++++++++++ .github/ISSUE_TEMPLATE/bug_report.md | 51 -------------- .github/ISSUE_TEMPLATE/feature_request.md | 33 --------- 5 files changed, 160 insertions(+), 84 deletions(-) create mode 100644 .github/ISSUE_TEMPLATE/01-bug-report.yml create mode 100644 .github/ISSUE_TEMPLATE/02-feature-request.yml create mode 100644 .github/ISSUE_TEMPLATE/03-documentation.yml delete mode 100644 .github/ISSUE_TEMPLATE/bug_report.md delete mode 100644 .github/ISSUE_TEMPLATE/feature_request.md diff --git a/.github/ISSUE_TEMPLATE/01-bug-report.yml b/.github/ISSUE_TEMPLATE/01-bug-report.yml new file mode 100644 index 0000000..d1dedde --- /dev/null +++ b/.github/ISSUE_TEMPLATE/01-bug-report.yml @@ -0,0 +1,67 @@ +# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms +# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema + +name: "Bug report" +description: "You've found a bug? Does the library not behave as expected?" +title: "[BUG] " +labels: ["bug"] + +body: + + - type: markdown + attributes: + value: "You've found a bug? Does the library not behave as expected?\nPlease help us to improve this project and fill out the following form.\nIf you are unsure whether it is a bug, or you have a question or an issue that is not a bug, please go to [the discussions section](../discussions) instead. Thanks!" + + - type: textarea + validations: + required: true + attributes: + label: "Issue description" + description: "Please describe the bug or unexpected behaviour, add screenshots to help explain the problem if applicable." + placeholder: "A clear and concise description of the issue" + + - type: textarea + validations: + required: true + attributes: + label: "Expected behavior" + description: "Please describe what you expected to happen or how the library should behave in this case." + placeholder: "A clear and concise description of what you expected to happen" + + - type: textarea + validations: + required: false + attributes: + label: "Code sample" + description: "If applicable, please add a code sample that reproduces the issue.\nNote: the content of this textarea will be rendered as PHP code!" + placeholder: "PHP code" + render: php + + - type: dropdown + id: version + validations: + required: true + attributes: + label: "Library version" + description: "What version of the library are you running?" + options: + - "latest" + - "dev-main" + - "6.x" + - "5.x" + - "4.x" + - "3.x" + - "2.x" + - "1.x" + default: 0 + + - type: textarea + validations: + required: false + attributes: + label: "Additional context" + description: "Add any other context that might be of use here, e.g. exact library version, PHP Version, operating system, other code snippets..." + + - type: markdown + attributes: + value: "Thanks for taking the time to fill out this issue report!" diff --git a/.github/ISSUE_TEMPLATE/02-feature-request.yml b/.github/ISSUE_TEMPLATE/02-feature-request.yml new file mode 100644 index 0000000..f18d1ec --- /dev/null +++ b/.github/ISSUE_TEMPLATE/02-feature-request.yml @@ -0,0 +1,53 @@ +# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms +# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema + +name: "Feature request" +description: "You have an idea for a new feature?" +title: "[ENHANCEMENT] " +labels: ["enhancement"] + +body: + + - type: markdown + attributes: + value: "You have an idea for a new feature (or improve an existing one)? Great!\nPlease help us to improve this project and fill out the following form.\nIf you have a question or an issue that is not a feature request, please go to [the discussions section](../discussions) instead. Thanks!" + + - type: textarea + validations: + required: true + attributes: + label: "Feature description" + description: "Please describe the requested feature." + placeholder: "A clear and concise description of the requested feature" + + - type: textarea + validations: + required: false + attributes: + label: "Code sample" + description: "If applicable, please add a code sample to illustrate the feature.\nNote: the content of this textarea will be rendered as PHP code!" + placeholder: "PHP code" + render: php + + - type: textarea + validations: + required: false + attributes: + label: "Additional context" + description: "Add any other context that might be of use here, e.g. other code snippets..." + + - type: dropdown + validations: + required: true + id: pr + attributes: + label: "Pull Request" + description: "**Are you (the requester) willing to submit a pull request for that feature?**\nA yes will greatly increase the chance that the feature will be added." + options: + - "" + - "No - I can't/won't submit a PR" + - "Yes - I will submit a PR" + + - type: markdown + attributes: + value: "Thanks for taking the time to fill out this feature request!" diff --git a/.github/ISSUE_TEMPLATE/03-documentation.yml b/.github/ISSUE_TEMPLATE/03-documentation.yml new file mode 100644 index 0000000..656a837 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/03-documentation.yml @@ -0,0 +1,40 @@ +# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms +# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-githubs-form-schema + +name: "Documentation" +description: "There's a documentation issue?" +title: "[DOCS] " +labels: ["docs"] + +body: + + - type: markdown + attributes: + value: "There's an issue with the documentation or you have a proposal for an addition?\nPlease help us to improve this project and fill out the following form.\nIf you have a question or an issue that has nothing to do with the documentation, please go to [the discussions section](../discussions) instead. Thanks!" + + - type: textarea + validations: + required: true + attributes: + label: "Description" + description: "Please describe the documentation issue or addition." + placeholder: "A clear and concise description of the issue or addition" + + - type: textarea + validations: + required: false + attributes: + label: "Proposed change/addition" + description: "If applicable, please add the proposed change here." + placeholder: "The new or changed documentation text" + + - type: textarea + validations: + required: false + attributes: + label: "Additional context" + description: "Add any other context here, for example a link to the current documentation or an issue/discussion for reference." + + - type: markdown + attributes: + value: "Thanks for taking the time to fill out this issue report!" diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index d4d5471..0000000 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,51 +0,0 @@ ---- -name: Bug report -about: You have found a bug? Does the library not behave as expected? That's great (ok, not that great)! Please help us to improve! -title: '[BUG]' -labels: 'bug' ---- - - - -**Describe the bug or unexpected behaviour** - -A clear and concise description of what the bug is. - - -**Steps to reproduce the behavior** - -- When i do ... -- The code below ... -- Error message: ... - - -**Code sample** (if applicable) - -```php -// your code here -``` - - -**Expected behavior** - -A clear and concise description of what you expected to happen. - - -**Screenshots** - -If applicable, add screenshots to help explain your problem. - - -**Environment (please complete the following information):** - -- PHP version/OS: [e.g. 7.4.12, Ubuntu 20.04] -- Library version: [e.g. 4.3.1] - - -**Additional context** - -Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md deleted file mode 100644 index 22e8669..0000000 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ /dev/null @@ -1,33 +0,0 @@ ---- -name: Feature request -about: You have an idea for a new feature (or improve an existing one)? Great! -title: '[ENHANCEMENT]' -labels: 'enhancement' ---- - - - -**Describe the feature** - -A clear and concise description of the requested feature. - - -**Code sample** (if applicable) - -```php -// your code here -``` - - -**Additional context** - -Add any other context here (if applicable). - - -**Are you (the requester) willing to submit a pull request for that feature?** - -[YES|NO] (A yes will greatly increase the chance that the feature will be added)