Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @BlessInSoftware/ZeroDay
93 changes: 93 additions & 0 deletions .github/COMMIT_CONVENTION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
# Git conventional commit messages

> Note
> This is adapted from [Discord.js commit convention](https://github.com/discordjs/discord.js/blob/main/.github/COMMIT_CONVENTION.md) and [Conventional commits](https://www.conventionalcommits.org).

## TL;DR

Messages must be matched by the following regex:

```js
/^(revert: )?(feat(\(.+\))?:|fix(\(.+\))?:|docs(\(.+\))?:|style(\(.+\))?:|refactor(\(.+\))?:|perf(\(.+\))?:|test(\(.+\))?:|build(\(.+\))?:|ci(\(.+\))?:|chore(\(.+\))?:) .{1,72}/;
```

### Examples

Appears under "features" header, `scope` subheader:

```text
feat(scope): add 'tag' method
```

Appears under "fixes" header, `scope` subheader, with a link to issue #1:

```text
fix(scope): handle events correctly

close #1
```

Appears under "performance" header, and under "Breaking Changes" with the breaking change explanation:

```text
perf(core)!: improve patching by removing 'bar' option

BREAKING CHANGE: The 'bar' option has been removed.
```

The following commit and commit `410fbbc` do not appear in the changelog if they are under the same release. If not, the revert commit appears under the "Reverts" header.

```text
revert: feat(Managers): add Managers

This reverts commit 410fbbc5c4d0072b9bb97a466f56b07c90b926be.
```

### Full Message Format

A commit message consists of a **header**, **body** and **footer**. The header has a **type**, **scope** and **subject**:

```text
<type>(<scope>): <subject>
<BLANK LINE>
<body>
<BLANK LINE>
<footer>
```

> **Note**
> The **header** is mandatory and the **scope** of the header is optional.
> If you aren't using it, it should look like this: `<type>: <subject>`

### Revert

If the commit reverts a previous commit, it should begin with `revert:`, followed by the header of the reverted commit. In the body, it should say: `This reverts commit <hash>.`, where the hash is the SHA of the commit being reverted.

### Type

If the prefix is `feat`, `fix` or `perf`, it will appear in the changelog. However, if there is any [BREAKING CHANGE](#footer), the commit will always appear in the changelog.

Other prefixes are up to your discretion. Suggested prefixes are `docs`, `chore`, `style`, `refactor`, and `test` for non-changelog related tasks.

### Scope

The scope could be anything specifying the place of the commit change. For example `Object`, `Array`, `Class` etc.

### Subject

The subject contains a succinct description of the change:

- use the imperative, present tense: "change" not "changed" nor "changes"
- don't capitalize the first letter
- no dot (.) at the end

### Body

Just as in the **subject**, use the imperative, present tense: "change" not "changed" nor "changes".
The body should include the motivation for the change and contrast this with previous behavior.

### Footer

The footer should contain any information about **Breaking Changes** and is also the place to reference GitHub issues that this commit **Closes**.

**Breaking Changes** should start with the word `BREAKING CHANGE:` with a space or two newlines. The rest of the commit message is then used for this.
1 change: 1 addition & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github: [IvanGodinez21]
21 changes: 21 additions & 0 deletions .github/ISSUE_TEMPLATE/bug.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Bug
title: '[Bug]: '
description: Template for discovered bugs.
labels: [bug]
body:
- type: textarea
id: description
attributes:
label: Description
description: A clear and concise description of what the problem is, or what feature you want to be implemented.
placeholder: Describe the bug.
validations:
required: true
- type: textarea
id: solution
attributes:
label: Ideal solution or implementation
description: A clear and concise description of what you want to happen.
placeholder: Describe a possible solution.
validations:
required: false
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
blank_issues_enabled: false
21 changes: 21 additions & 0 deletions .github/ISSUE_TEMPLATE/feature.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Feature
title: '[Feature]: '
description: Template for new features.
labels: [enhancement]
body:
- type: textarea
id: description
attributes:
label: Description
description: A detailed description for this issue, provide all necessary information so any member of the project understands. You can describe or use the following template -> As a `<type of user>`, I want `<some goal>` so that `<some reason>`.
placeholder: Describe the feature.
validations:
required: true
- type: textarea
id: design
attributes:
label: Design
description: Provide references to images of the design, how it looks now, and how it should look like.
placeholder: Attach images or links to images.
validations:
required: false
20 changes: 20 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Description

> Describe the changes made by this pull request.

## Related issues

> List related issues (if any) and/or @mentions of the person or team responsible for reviewing proposed changes (left blank if not applicable).
> List by using - [ ] and the issue number, e.g. `- [ ] #1` or `- [x] #1` if the issue is closed/solved.

## Testing

> Help me how can I test or look at the changes (left blank if not applicable).

## Screenshots

> Include screenshots of the results or screenshots that help to see changes (left blank if not applicable).

## Notes

> Some additional notes if necessary (left blank if not applicable).
28 changes: 28 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Coverage
on:
pull_request:
push:
branches:
- main
workflow_dispatch:
jobs:
collect-and-upload-coverage:
name: Run tests, collect and upload coverage
runs-on: ubuntu-latest
steps:
- name: 🏗️ Setup repository
uses: actions/checkout@v4

- name: 🏗️ Setup Bun
uses: oven-sh/setup-bun@v1

- name: 📦 Install dependencies
run: bun install

- name: 🧪 Run tests and collect coverage
run: bun test --coverage

- name: 📤 Upload coverage to Codacy
uses: codacy/codacy-coverage-reporter-action@v1.3.0
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}