Skip to content

Commit

Permalink
Bug report template: various tweaks
Browse files Browse the repository at this point in the history
* Improve readability of reports by using headers.
* Improve readability of the versions list by using a table.
* Explicitly say that screenshots of code are not acceptable as a code sample.
* Added an "Install type" entry to the versions list
* Added an extra checklist for bug reporters in an attempt to reduce the number of issues which should never have been opened in the first place.
  • Loading branch information
jrfnl committed May 23, 2023
1 parent 2dc7b59 commit 70476e5
Showing 1 changed file with 22 additions and 12 deletions.
34 changes: 22 additions & 12 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,23 @@ Please report bugs for externally maintained sniffs to the appropriate external
standard repository (not here).
-->

**Describe the bug**
## Describe the bug
A clear and concise description of what the bug is.

**Code sample**
### Code sample
```php
echo "A short code snippet that can be used to reproduce the bug";
echo "A short code snippet that can be used to reproduce the bug. Do NOT paste screenshots of code!";
```

**Custom ruleset**
### Custom ruleset
```xml
<?xml version="1.0"?>
<ruleset name="My Custom Standard">
<description>If you are using a custom ruleset, please enter it here.</description>
</ruleset>
```

**To reproduce**
### To reproduce
Steps to reproduce the behavior:
1. Create a file called `test.php` with the code sample above...
2. Run `phpcs test.php ...`
Expand All @@ -43,14 +43,24 @@ Steps to reproduce the behavior:
PHPCS output here
```

**Expected behavior**
## Expected behavior
A clear and concise description of what you expected to happen.

**Versions (please complete the following information):**
- OS: [e.g., Windows 10, MacOS 10.15]
- PHP: [e.g., 7.2, 7.4]
- PHPCS: [e.g., 3.5.5, master]
- Standard: [e.g., PSR2, PSR12, Squiz]
## Versions (please complete the following information)

**Additional context**
| | |
|-------------------------|------------------------------------------------------------------------------|
| Operating System | [e.g., Windows 10, MacOS 10.15] |
| PHP version | [e.g., 7.2, 7.4] |
| PHP_CodeSniffer version | [e.g., 3.5.5, master] |
| Standard | [e.g., PSR2, PSR12, Squiz, custom] |
| Install type | [e.g. Composer (global/local), PHAR, PEAR, git clone, other (please expand)] |

## Additional context
Add any other context about the problem here.

## Please confirm:

- [ ] I have searched the issue list and am not opening a duplicate issue.
- [ ] I confirm that this bug is a bug in PHP_CodeSniffer and not in one of the external standards.
- [ ] I have verified the issue still exists in the `master` branch of PHP_CodeSniffer.

0 comments on commit 70476e5

Please sign in to comment.