Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: enforce usage of scopes in PR title #3672

Merged
merged 4 commits into from
Nov 28, 2023

Conversation

scarf005
Copy link
Member

@scarf005 scarf005 commented Nov 15, 2023

Purpose of change

followup of #3536, enforces much stricter PR title convention for

  • better commit log
  • easier changelog generation.

from now on, changelog guidelines will be strictly enforced via semantic PR bot.
it means adding invalid mod ids like fix(mods/foobar): baz to PR title is now forbidden.

Describe the solution

  • blocked by build: use import map for ts imports #3674
  • created scripts/semantic.ts that grabs all mainlined mod ids to autogenerate appropriate mods/<MOD_ID> scope. this allows future tool to add tag/sort/group PRs by affected mods. Currently it's meant to be ran manually since we don't add/remove mainlined mods often.
  • now the autofix action also lints and tests typescript files automatically

Alternatives

maybe map scopes could be useful.

Additional Context

please mention if the script is confusing or too complex. I'm eager to improve documentation.

@github-actions github-actions bot added the scripts related to game management scripts label Nov 15, 2023
@scarf005 scarf005 changed the title ci semantic scopes ci: enforce usage of BN scopes Nov 15, 2023
@scarf005 scarf005 changed the title ci: enforce usage of BN scopes ci: enforce usage of scopes Nov 15, 2023
@scarf005 scarf005 changed the title ci: enforce usage of scopes ci: enforce usage of scopes in PR title Nov 15, 2023
@scarf005 scarf005 requested a review from Coolthulhu November 15, 2023 05:21
@Coolthulhu
Copy link
Member

How does it work if someone wanted to add a new mod?

@scarf005
Copy link
Member Author

scarf005 commented Nov 22, 2023

The script could be also added on autofix.ci workflow but i think me adding the mod name in semantic.yml manually would be sufficient. that is, running deno run -A scripts/semantic.ts will update list of valid mods.

@chaosvolt chaosvolt added this pull request to the merge queue Nov 28, 2023
Merged via the queue into cataclysmbnteam:upload with commit 660cef0 Nov 28, 2023
12 checks passed
@scarf005 scarf005 deleted the ci-semantic-scopes branch November 28, 2023 22:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scripts related to game management scripts
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants