diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 1031d2038faf..20d703e5cc7b 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -12,32 +12,18 @@ WARNING: If autofix.ci app did the formatting for you, YOU MUST DO EITHER OF THE If you don't do this, your following work will be based on the old commit, and may cause MERGE CONFLICT. If you use GitHub's web editor to edit files, you shouldn't need to do this as the web editor works directly on the remote branch. -Please use a descriptive name for the PR title, so it's clear at a glance what the PR is about. ---> -## Summary -SUMMARY: Category "Brief description of the change" +PR TITLE: Please follow conventional commits: https://www.conventionalcommits.org +This makes it clear at a glance what the PR is about. - ## Purpose of change diff --git a/.github/semantic.yml b/.github/semantic.yml new file mode 100644 index 000000000000..4f01b5685692 --- /dev/null +++ b/.github/semantic.yml @@ -0,0 +1,3 @@ +# https://github.com/Ezard/semantic-prs?tab=readme-ov-file#configuration-options +# Validate the PR title, and ignore all commit messages +titleOnly: true diff --git a/.github/workflows/pull-translations.yml b/.github/workflows/pull-translations.yml index 79706e7a8b6b..16cedba7cc5c 100644 --- a/.github/workflows/pull-translations.yml +++ b/.github/workflows/pull-translations.yml @@ -27,13 +27,13 @@ jobs: - name: Create Pull Request uses: peter-evans/create-pull-request@v3.10.0 with: - commit-message: Routine i18n updates on ${{ steps.get-timestamp.outputs.time }} + commit-message: "feat(i18n): routine i18n updates on ${{ steps.get-timestamp.outputs.time }}" committer: Coolthulhu (BOT) author: Coolthulhu (BOT) token: ${{ secrets.TX_PR_CREATOR }} branch: i18n delete-branch: true base: upload - title: Routine i18n updates on ${{ steps.get-timestamp.outputs.time }} - body: "#### Summary\nNone" + title: "feat(i18n): routine i18n updates on ${{ steps.get-timestamp.outputs.time }}" + body: "" labels: Translation diff --git a/doc/src/content/docs/en/contribute/changelog_guidelines.md b/doc/src/content/docs/en/contribute/changelog_guidelines.md index 732db059db9b..40745957902f 100644 --- a/doc/src/content/docs/en/contribute/changelog_guidelines.md +++ b/doc/src/content/docs/en/contribute/changelog_guidelines.md @@ -2,20 +2,86 @@ title: Changelog Guidelines --- -- categories used by `Pull Request Summary` in the - [PR Template](https://github.com/cataclysmbnteam/Cataclysm-BN/blob/upload/.github/pull_request_template.md). -- these are only guidelines, not rules. choose the best category for your PR freely. +PR title follows [Convensional Commits](https://www.conventionalcommits.org/en/v1.0.0/) for easier +changelog generation. The format is one of: -## Features +``` +: +(, , ...): +``` + +For Example, a PR title can be: + +``` +feat: add new mutation +feat(content, port): port mutation description from DDA +``` + +## Category + +The category is the first word in the PR title. They specify the type of change being made. When in +doubt, use `feat` for new features, and `fix` for bugfixes. Here are some frequently used +categories: + +### `feat`: Features + +New features, additions, or balance changes. + +### `fix`: Bugfixes + +Anything that fixes a bug or makes the game more stable. + +### `refactor`: Infrastructure + +Make development easier without changing its behavior. For example: + +- `C++` refactorings and overhaul +- `Json` reorganizations +- `docs/`, `.github/` and repository changes +- other development tools + +### `build`: Build + +Improve build process: + +- more robust +- easier to use +- faster compile time + +### Others + +- `docs`: Documentation changes +- `style`: Code style changes (whitespace, formatting, etc), usu. fixing JSON formatting. +- `perf`: Performance Improvements +- `test`: Adding missing tests or correcting existing tests +- `ci`: Changes to CI process +- `chore`: Other changes that don't fit into any of the above categories +- `revert`: Reverts a previous commit + +## Scopes + +1. Use them inside parentheses after the category to further narrow the scope of your PR. +2. There are no limits to number of scopes. +3. They are optional, but recommended. +4. these are only guidelines, not rules. choose the best one for your PR freely! + +### ``: Player/Worldwide Features Changes related to player: - player can do something new (e.g: mutations, skills) - something new can happen to the player (e.g: new disease) -## Content +Example PR title: -Added new contents like: +``` +feat: strength training activity +feat: mutation system overhaul +``` + +### `content`: Contents + +New contents like: - new monsters - new map areas @@ -23,7 +89,14 @@ Added new contents like: - new vehicles - new doohickeys -## Interface +Example PR title: + +``` +feat(content): semi-plausible smokeless gunpowder recipe +feat(content, port): game store +``` + +### `UI`: Interfaces UI/UX changes like: @@ -32,40 +105,47 @@ UI/UX changes like: - streamlining workflows - quality of life improvements -## Mods +Example PR title: -- changes contained within a mod -- extends what is capable within a mod +``` +feat(UI): More info about items dropped with bags +feat(UI): overhaul encumbrance UI +``` -## Balance +### `i18n`: Internationalization -Changes to game balance. +Improve translation and other languages support. -## Bugfixes +``` +fix(UI, i18n): recipe names not translated unless learned +``` -Fixes for anything broken. +### `mods/`: Mods -## Performance +- changes contained within a mod +- extends what is capable within a mod -Improvements to game performance. +Example PR title: -## Infrastructure +``` +feat(mods/magiclysm, content): add missing owlbear pelts recipe +fix(mods/no_hope): No Hope doesn't make the world freezing +``` -Make development easier: +### `balance`: Balance Changes -- `C++` refactorings and overhaul -- `Json` reorganizations -- `docs/`, `.github/` and repository changes -- other development tools +Changes to game balance. -## Build +Example PR title: -Improve build process: +``` +feat(balance): Give moose pelts instead of hides +``` -- more robust -- easier to use -- faster compile time +### `port`: Ports from DDA or other forks -## I18N +Example PR title: -Improve translation and other languages support. +``` +feat(content, port): game shop +```