Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
3ldor committed Nov 22, 2024
0 parents commit 3602cb8
Show file tree
Hide file tree
Showing 4 changed files with 221 additions and 0 deletions.
128 changes: 128 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
name: Bug Report
description: Report a bug with one of our game clients.
labels: ["bug"]

body:
# Bug details
- type: markdown
attributes:
value: |
### Thanks for taking the time to fill out this bug report!
Only actual **bug** reports are accepted here. For general support or questions, please visit our [Forum](https://forum.plutonium.pw) or [Discord](https://discord.gg/plutonium).
Please search to see if an issue already exists for the bug you encountered before reporting it.
---
- type: textarea
id: summary
attributes:
label: What happened?
description: |
Please describe the issue as well as you can.
If relevant, remember to attach any crash dumps and GSC scripts. Screenshots and screen recordings can be of help too.
validations:
required: true

- type: textarea
id: expectation
attributes:
label: Expected result
description: What did you expect would happen?
validations:
required: true

- type: textarea
id: repro
attributes:
label: Steps to reproduce
description: How can we as simply and reliably as possible reproduce the issue?
placeholder: |
1.
2.
3.
validations:
required: true

- type: dropdown
id: game
attributes:
label: Affected game(s)
description: Which game(s) does the issue affect?
multiple: true
options:
- BO2 Multiplayer (T6MP)
- BO2 Zombies (T6ZM)
- MW3 Multiplayer (IW5MP)
- BO1 Multiplayer (T5MP)
- BO1 Zombies (T5SP)
- WaW Multiplayer (T4MP)
- WaW Co-Op/Zombies (T4SP)
validations:
required: true

- type: dropdown
id: component
attributes:
label: Affected component(s)
description: Which component(s) does the issue affect?
multiple: true
options:
- Client (game)
- Server (dedi)
validations:
required: true

- type: input
id: version
attributes:
label: Plutonium version
description: Which Plutonium version did the issue occur on?
placeholder: "Example: r4516"
validations:
required: true

- type: textarea
id: logs
attributes:
label: Relevant logs
description: Please copy and paste any relevant client or server log output.

- type: textarea
id: extra
attributes:
label: Additional information
description: Any additional information you'd like to add.

# System information
- type: markdown
attributes:
value: |
## System information
Please provide information about the system the bug occurs on.
- type: input
id: system-os
attributes:
label: Operating system
description: The operating system (and preferably version) Plutonium is running on.
placeholder: "Example: Windows 11 23H2"

# Contact details
- type: markdown
attributes:
value: |
## Contact details
If you want, you can provide some additional contact info so we can reach you easier.
- type: input
id: contact-plutonium
attributes:
label: Plutonium profile
description: Link to your Plutonium profile.
placeholder: https://forum.plutonium.pw/user/

- type: input
id: contact-discord
attributes:
label: Discord username
placeholder: wumpus
9 changes: 9 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
blank_issues_enabled: false
contact_links:
- name: Community Forum
url: https://forum.plutonium.pw
about: For general support or questions. Try the search feature!

- name: Discord
url: https://discord.gg/plutonium
about: For problems with your Plutonium account, or more direct communication.
83 changes: 83 additions & 0 deletions .github/workflows/issue_opened.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
name: Label issues
on:
issues:
types: [opened, reopened]

env:
ISSUE_BODY: ${{ github.event.issue.body }}

jobs:
label_issue:
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- uses: actions/github-script@v7
with:
script: |
const gameRegex = /### Affected game\(s\)\s*(.*)/;
const componentRegex = /### Affected component\(s\)\s*(.*)/;
const valueRegex = /\s*[,\n]\s*/;
const gameLabelMap = {
'IW5': 'game: IW5',
'T6': 'game: T6',
'T5': 'game: T5',
'T4': 'game: T4'
};
const mpLabel = 'mode: MP';
const zmLabel = 'mode: ZM';
const clientLabel = 'component: client';
const serverLabel = 'component: server';
const issueBody = process.env.ISSUE_BODY;
const labelsToAdd = new Set();
const gameMatches = gameRegex.exec(issueBody);
if (gameMatches && gameMatches.length > 1) {
const games = gameMatches[1].split(valueRegex);
// add 'game: ' labels
for (const game of games) {
for (const [gameMatch, label] of Object.entries(gameLabelMap)) {
if (game.includes(gameMatch)) {
labelsToAdd.add(label);
break;
}
}
}
// add 'mode: ' label
if (games.every(g => g.includes('MP'))) {
labelsToAdd.add(mpLabel);
}
else if (games.every(g => g.includes('ZM') || g.includes('SP'))) {
labelsToAdd.add(zmLabel);
}
}
const componentMatches = componentRegex.exec(issueBody);
if (componentMatches && componentMatches.length > 1) {
const components = componentMatches[1].split(valueRegex);
// add 'component: ' labels
for (const component of components) {
if (component.includes('Client')) {
labelsToAdd.add(clientLabel);
}
if (component.includes('Server')) {
labelsToAdd.add(serverLabel);
}
}
}
if (labelsToAdd.size === 0) {
return;
}
github.rest.issues.addLabels({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
labels: Array.from(labelsToAdd),
});
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Plutonium Bug Tracker

0 comments on commit 3602cb8

Please sign in to comment.