diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index d611d8c9..79de77ba 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -13,3 +13,16 @@ To get ready to work on the codebase, please do the following: 5. Make your changes 6. Run `pnpm format && pnpm build && pnpm test:unit` to run ESLint/Prettier, build and tests 7. [Submit a pull request](https://github.com/NanoForge-dev/Engine/compare) (Make sure you follow the [conventional commit format](https://github.com/NanoForge-dev/Engine/blob/main/.github/COMMIT_CONVENTION.md)) + +## Releases + +Releases use the shared workflows of [NanoForge-dev/actions](https://github.com/NanoForge-dev/actions) (`@v3`), configured in `.github/nanoforge.json`: + +- `engine`: the runtime packages, one `shared` version for all of them, tagged ``. Its releases also sync the docs. +- `utils`: `utils-eslint-config` and `utils-prettier-config`, released one at a time with their own version, tagged `@`. + +1. Run the **Release PR** workflow (Actions tab). Leave `group` empty for `engine`, or set `utils` and the package in `packages`. Leave `version` empty to take it from the commits, and use `dry-run` to preview. +2. Review and merge the `releases/*` pull request with "Squash and merge". +3. Merging it triggers the **Release** workflow: it publishes the changed packages on npm, tags them, creates the GitHub release and, for `engine`, syncs the docs. + +Run the **Alpha Release** workflow from a feature branch to publish an alpha of the packages listed in `packages`. Other merged pull requests release nothing: no group has `betaOnMerge`. diff --git a/.github/actions/emsdk-install/action.yml b/.github/actions/emsdk-install/action.yml index 0672f60a..d7a6b1bb 100644 --- a/.github/actions/emsdk-install/action.yml +++ b/.github/actions/emsdk-install/action.yml @@ -10,12 +10,6 @@ inputs: runs: using: "composite" steps: - - name: Set up swap space - if: runner.os == 'Linux' - uses: pierotofy/set-swap-space@v1.0 - with: - swap-size-gb: 10 - - name: Cache rotation keys id: cache-rotation shell: bash diff --git a/.github/actions/prepare/action.yml b/.github/actions/prepare/action.yml index 1f6fedc3..1b1ac185 100644 --- a/.github/actions/prepare/action.yml +++ b/.github/actions/prepare/action.yml @@ -1,30 +1,14 @@ name: prepare -description: Prepare action -inputs: - pnpm-install: - description: Install pnpm depedencies - default: "true" - emsdk-install: - description: Install emscriptens - default: "true" - build: - description: Build packages - default: "true" +description: Installs Node.js, pnpm and the dependencies, then emsdk, then builds the packages runs: using: composite steps: - - if: inputs.pnpm-install == 'true' - name: Install pnpm and Node.js - uses: pnpm/setup@c9883cc79df532ad1a7b81bf9ab944ceb090d65c - with: - runtime: node@26 - cache: true + - name: Set up Node.js, pnpm and the dependencies + uses: nanoforge-dev/actions/setup@v3 - - if: inputs.emsdk-install == 'true' - name: Install emsdk + - name: Install emsdk uses: ./.github/actions/emsdk-install - - if: inputs.build == 'true' - name: Build packages + - name: Build packages shell: bash run: pnpm run build diff --git a/.github/nanoforge.json b/.github/nanoforge.json new file mode 100644 index 00000000..78a62e0c --- /dev/null +++ b/.github/nanoforge.json @@ -0,0 +1,34 @@ +{ + "$schema": "https://raw.githubusercontent.com/NanoForge-dev/actions/v3/schema/nanoforge.schema.json", + "groups": [ + { + "name": "engine", + "packages": [ + "@nanoforge-dev/asset", + "@nanoforge-dev/common", + "@nanoforge-dev/core", + "@nanoforge-dev/ecs", + "@nanoforge-dev/editor-lib", + "@nanoforge-dev/env", + "@nanoforge-dev/graphics-2d", + "@nanoforge-dev/graphics-3d", + "@nanoforge-dev/input", + "@nanoforge-dev/music", + "@nanoforge-dev/network", + "@nanoforge-dev/scene", + "@nanoforge-dev/sound" + ], + "mode": "all", + "versioning": "shared", + "branchFormat": "releases/nanoforge@{version}", + "commitFormat": "chore: release @nanoforge-dev/engine@{version}" + }, + { + "name": "utils", + "packages": ["@nanoforge-dev/utils-eslint-config", "@nanoforge-dev/utils-prettier-config"], + "mode": "single", + "versioning": "independent" + } + ], + "docs": { "category": "engine", "references": true } +} diff --git a/.github/workflows/alpha-release.yml b/.github/workflows/alpha-release.yml index 3abe0e82..673ed7c1 100644 --- a/.github/workflows/alpha-release.yml +++ b/.github/workflows/alpha-release.yml @@ -1,29 +1,15 @@ name: Alpha Release +# The alpha is -alpha..: the exact number is in the job summary. +run-name: Alpha release ${{ inputs.packages }} on ${{ github.ref_name }}${{ inputs.dry-run && ' (dry run)' || '' }} on: workflow_dispatch: inputs: - package: - description: "The published name of a single package to release" - type: choice - required: true - options: - - "@nanoforge-dev/asset" - - "@nanoforge-dev/common" - - "@nanoforge-dev/core" - - "@nanoforge-dev/ecs" - - "@nanoforge-dev/editor-lib" - - "@nanoforge-dev/env" - - "@nanoforge-dev/graphics-2d" - - "@nanoforge-dev/graphics-3d" - - "@nanoforge-dev/input" - - "@nanoforge-dev/music" - - "@nanoforge-dev/network" - - "@nanoforge-dev/scene" - - "@nanoforge-dev/sound" - - "@nanoforge-dev/utils-eslint-config" - - "@nanoforge-dev/utils-prettier-config" - dry_run: + packages: + description: Comma-separated packages (empty = the only package of .github/nanoforge.json) + type: string + default: "" + dry-run: description: Perform a dry run? type: boolean default: false @@ -33,23 +19,11 @@ permissions: id-token: write jobs: - alpha-release: + alpha: name: Alpha release - runs-on: ubuntu-latest - if: github.repository_owner == 'NanoForge-dev' - steps: - - name: Checkout repository - uses: actions/checkout@v7 - - - name: Prepare - uses: ./.github/actions/prepare - - - name: Release alpha - uses: ./node_modules/@nanoforge-dev/actions/actions/release-dev - with: - package: ${{ inputs.package }} - tag: alpha - dry: ${{ inputs.dry_run }} - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + uses: nanoforge-dev/actions/.github/workflows/alpha-release.yml@v3 + with: + packages: ${{ inputs.packages }} + dry-run: ${{ inputs.dry-run }} + secrets: + NPM_PUBLISH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }} diff --git a/.github/workflows/issue-triage.yml b/.github/workflows/issue-triage.yml index b5842151..294aba64 100644 --- a/.github/workflows/issue-triage.yml +++ b/.github/workflows/issue-triage.yml @@ -1,15 +1,13 @@ -name: "Issue Labeler" +name: Issue Triage + on: issues: types: [opened] + +permissions: + issues: write + jobs: - issue-triage: - permissions: - issues: write - runs-on: ubuntu-latest - steps: - - uses: github/issue-labeler@v3.5 - with: - repo-token: "${{ secrets.GITHUB_TOKEN }}" - configuration-path: .github/issue-labeler.yml - enable-versioned-regex: 0 + triage: + name: Triage + uses: nanoforge-dev/actions/.github/workflows/issue-triage.yml@v3 diff --git a/.github/workflows/label-sync.yml b/.github/workflows/label-sync.yml index 507f0211..370951f7 100644 --- a/.github/workflows/label-sync.yml +++ b/.github/workflows/label-sync.yml @@ -1,4 +1,5 @@ -name: "Label sync" +name: Label Sync + on: workflow_dispatch: push: @@ -6,19 +7,12 @@ on: - main paths: - ".github/labels.yml" + +permissions: + contents: read + issues: write + jobs: label-sync: name: Label sync - permissions: - contents: read - issues: write - runs-on: ubuntu-latest - if: github.repository_owner == 'NanoForge-dev' - steps: - - name: Checkout repository - uses: actions/checkout@v7 - - - name: Label sync - uses: crazy-max/ghaction-github-labeler@v6 - with: - github-token: ${{ secrets.GITHUB_TOKEN }} + uses: nanoforge-dev/actions/.github/workflows/label-sync.yml@v3 diff --git a/.github/workflows/pr-triage.yml b/.github/workflows/pr-triage.yml index 176638af..c3bc8ef9 100644 --- a/.github/workflows/pr-triage.yml +++ b/.github/workflows/pr-triage.yml @@ -1,4 +1,5 @@ -name: "PR Triage" +name: PR Triage + on: pull_request_target: types: @@ -6,33 +7,13 @@ on: - edited - reopened - synchronize -jobs: - label: - permissions: - contents: read - pull-requests: write - issues: write - name: Label - if: github.event.action != 'edited' - runs-on: ubuntu-latest - steps: - - name: Label pull request - uses: actions/labeler@v7 - with: - repo-token: "${{ secrets.GITHUB_TOKEN }}" - sync-labels: true - validate-title: - name: Validate title - runs-on: ubuntu-latest - steps: - - name: Validate pull request title - env: - TITLE: ${{ github.event.pull_request.title }} - run: | - REGEX="^(revert: )?(feat|fix|docs|style|refactor|perf|test|build|ci|chore|types)(\\(.+\\))?!?: .{1,72}$" - echo "Title: \"$TITLE\"" +permissions: + contents: read + pull-requests: write + issues: write - if [[ ! "$TITLE" =~ $REGEX ]]; then - exit 1 - fi +jobs: + triage: + name: Triage + uses: nanoforge-dev/actions/.github/workflows/pr-triage.yml@v3 diff --git a/.github/workflows/pre-release-single.yml b/.github/workflows/pre-release-single.yml deleted file mode 100644 index eeccc0c5..00000000 --- a/.github/workflows/pre-release-single.yml +++ /dev/null @@ -1,48 +0,0 @@ -name: Pre-Release Single - -on: - workflow_dispatch: - inputs: - package: - description: The published name of a single package to release - type: choice - required: true - options: - - "@nanoforge-dev/utils-eslint-config" - - "@nanoforge-dev/utils-prettier-config" - version: - description: New version for the packages - type: string - required: true - dry_run: - description: Perform a dry run? - type: boolean - default: false - -permissions: - contents: write - pull-requests: write - -jobs: - create-release-pr: - name: Create release pr - runs-on: ubuntu-latest - if: github.repository_owner == 'NanoForge-dev' - steps: - - name: Checkout repository - uses: actions/checkout@v7 - with: - fetch-depth: 0 - fetch-tags: true - - - name: Prepare - uses: ./.github/actions/prepare - - - name: Create release PR - uses: ./node_modules/@nanoforge-dev/actions/actions/create-packages-release-pr - with: - packages: ${{ inputs.package }} - version: ${{ inputs.version }} - dry: ${{ inputs.dry_run }} - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/pre-release.yml b/.github/workflows/pre-release.yml deleted file mode 100644 index e62023ac..00000000 --- a/.github/workflows/pre-release.yml +++ /dev/null @@ -1,43 +0,0 @@ -name: Pre-Release - -on: - workflow_dispatch: - inputs: - version: - description: New version for the packages - type: string - required: true - dry_run: - description: Perform a dry run? - type: boolean - default: false - -permissions: - contents: write - pull-requests: write - -jobs: - create-release-pr: - name: Create release pr - runs-on: ubuntu-latest - if: github.repository_owner == 'NanoForge-dev' - steps: - - name: Checkout repository - uses: actions/checkout@v7 - with: - fetch-depth: 0 - fetch-tags: true - - - name: Prepare - uses: ./.github/actions/prepare - - - name: Create release PR - uses: ./node_modules/@nanoforge-dev/actions/actions/create-packages-release-pr - with: - packages: "@nanoforge-dev/asset,@nanoforge-dev/common,@nanoforge-dev/core,@nanoforge-dev/ecs,@nanoforge-dev/editor-lib,@nanoforge-dev/env,@nanoforge-dev/graphics-2d,@nanoforge-dev/graphics-3d,@nanoforge-dev/input,@nanoforge-dev/music,@nanoforge-dev/network,@nanoforge-dev/scene,@nanoforge-dev/sound" - version: ${{ inputs.version }} - branch-format: "releases/nanoforge@{version}" - commit-format: "chore: release @nanoforge-dev/engine@{version}" - dry: ${{ inputs.dry_run }} - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/release-pr.yml b/.github/workflows/release-pr.yml new file mode 100644 index 00000000..c8e6ec50 --- /dev/null +++ b/.github/workflows/release-pr.yml @@ -0,0 +1,36 @@ +name: Release PR +run-name: Release PR ${{ inputs.group || '(first group)' }} ${{ inputs.packages }} ${{ inputs.version || '(auto version)' }}${{ inputs.dry-run && ' (dry run)' || '' }} + +on: + workflow_dispatch: + inputs: + group: + description: Release group of .github/nanoforge.json (empty = the first group) + type: string + default: "" + packages: + description: Comma-separated packages (empty = the group's mode decides) + type: string + default: "" + version: + description: Version (empty = from the commits, breaking → major, feat → minor, fix → patch) + type: string + default: "" + dry-run: + description: Perform a dry run? + type: boolean + default: false + +permissions: + contents: write + pull-requests: write + +jobs: + release-pr: + name: Release PR + uses: nanoforge-dev/actions/.github/workflows/release-pr.yml@v3 + with: + group: ${{ inputs.group }} + packages: ${{ inputs.packages }} + version: ${{ inputs.version }} + dry-run: ${{ inputs.dry-run }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9d1e733f..1bc708a7 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,4 +1,9 @@ name: Release +# The release PR title holds the versions (commitFormat); other merged PRs release nothing (no betaOnMerge group). +run-name: >- + ${{ !github.event.pull_request.merged && format('Closed without merge: {0}', github.event.pull_request.title) + || startsWith(github.head_ref, 'releases/') && format('Release: {0}', github.event.pull_request.title) + || format('No release: {0}', github.event.pull_request.title) }} on: pull_request: @@ -14,84 +19,8 @@ permissions: jobs: release: name: Release - runs-on: ubuntu-latest - if: github.repository_owner == 'NanoForge-dev' && github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/nanoforge@') - steps: - - name: Checkout repository - uses: actions/checkout@v7 - - - name: Prepare - uses: ./.github/actions/prepare - - - name: Release packages - uses: ./node_modules/@nanoforge-dev/actions/actions/release-packages - with: - packages: "@nanoforge-dev/asset,@nanoforge-dev/common,@nanoforge-dev/core,@nanoforge-dev/ecs,@nanoforge-dev/editor-lib,@nanoforge-dev/env,@nanoforge-dev/graphics-2d,@nanoforge-dev/graphics-3d,@nanoforge-dev/input,@nanoforge-dev/music,@nanoforge-dev/network,@nanoforge-dev/scene,@nanoforge-dev/sound" - tag-format: "{version}" - latest: true - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - release-single-package: - name: Release Single - runs-on: ubuntu-latest - if: github.repository_owner == 'NanoForge-dev' && github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/') && !startsWith(github.head_ref, 'releases/nanoforge@') - steps: - - name: Checkout repository - uses: actions/checkout@v7 - - - name: Prepare - uses: ./.github/actions/prepare - - - id: get-package - name: Get package name - uses: actions/github-script@v9.0.0 - with: - script: | - const branch = '${{ github.head_ref }}'; - const nameAndVersion = branch.replace('releases/', ''); - const name = nameAndVersion.split('@')[0]; - const package = `@nanoforge-dev/${name}`; - core.setOutput('package', package) - - - name: Release packages - uses: ./node_modules/@nanoforge-dev/actions/actions/release-packages - with: - packages: ${{ steps.get-package.outputs.package }} - latest: false - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }} - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - publish-docs: - name: Publish docs - runs-on: ubuntu-latest - if: github.repository_owner == 'NanoForge-dev' - needs: [release] - steps: - - name: Checkout repository - uses: actions/checkout@v7 - with: - fetch-depth: 0 - fetch-tags: true - - - name: Checkout docs repository - uses: actions/checkout@v7 - with: - fetch-depth: 0 - fetch-tags: true - path: docs-dist - repository: nanoforge-dev/docs - token: ${{ secrets.ACTIONS_KEY }} - - - name: Prepare - uses: ./.github/actions/prepare - - - name: Publish docs - uses: ./node_modules/@nanoforge-dev/actions/actions/synchronize-docs - with: - repository: engine - category: engine - references: true - references-path: docs/references + uses: nanoforge-dev/actions/.github/workflows/release.yml@v3 + secrets: + NPM_PUBLISH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }} + # The config has docs: the engine group's releases sync them into NanoForge-dev/docs. + NANOFORGE_DOCS_PRIVATE_KEY: ${{ secrets.NANOFORGE_DOCS_PRIVATE_KEY }} diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 4a3c222d..cf148d6f 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -4,6 +4,7 @@ on: pull_request: branches: - main + # Pushes to main fill the caches that pull requests restore. push: branches: - main @@ -14,28 +15,27 @@ on: type: boolean default: false +permissions: + contents: read + jobs: tests: - runs-on: ubuntu-latest - steps: - - name: Checkout repository - uses: actions/checkout@v7 - - - name: Prepare - uses: ./.github/actions/prepare - - - name: "Run tests" - run: pnpm test - - - name: "Run linter" - run: pnpm lint + name: Tests + uses: nanoforge-dev/actions/.github/workflows/tests.yml@v3 + with: + style-scripts: '["lint"]' + unit-script: test:unit + e2e-script: test:e2e graphics: + name: Graphics e2e tests # Pinned: the reference screenshots are rendered by this OS's Chromium and SwiftShader. runs-on: ubuntu-24.04 steps: - name: Checkout repository uses: actions/checkout@v7 + with: + persist-credentials: false - name: Prepare uses: ./.github/actions/prepare @@ -44,7 +44,11 @@ jobs: run: pnpm exec playwright install --with-deps chromium - name: Run graphics e2e tests - run: pnpm test:e2e:graphics ${{ inputs.update-snapshots && '--update-snapshots' || '' }} + env: + UPDATE_SNAPSHOTS: ${{ inputs.update-snapshots }} + run: | + if [ "$UPDATE_SNAPSHOTS" = true ]; then set -- --update-snapshots; fi + pnpm test:e2e:graphics "$@" - name: Upload report and screenshots if: always() diff --git a/modules/ecs/cliff.toml b/modules/ecs/cliff.toml index 5163767e..d6db6a4a 100644 --- a/modules/ecs/cliff.toml +++ b/modules/ecs/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/modules/editor/cliff.toml b/modules/editor/cliff.toml index 5163767e..d6db6a4a 100644 --- a/modules/editor/cliff.toml +++ b/modules/editor/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/modules/graphics-2d/cliff.toml b/modules/graphics-2d/cliff.toml index 5163767e..d6db6a4a 100644 --- a/modules/graphics-2d/cliff.toml +++ b/modules/graphics-2d/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/modules/graphics-3d/cliff.toml b/modules/graphics-3d/cliff.toml index 5163767e..d6db6a4a 100644 --- a/modules/graphics-3d/cliff.toml +++ b/modules/graphics-3d/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/modules/input/cliff.toml b/modules/input/cliff.toml index 5163767e..d6db6a4a 100644 --- a/modules/input/cliff.toml +++ b/modules/input/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/modules/music/cliff.toml b/modules/music/cliff.toml index 5163767e..d6db6a4a 100644 --- a/modules/music/cliff.toml +++ b/modules/music/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/modules/network/cliff.toml b/modules/network/cliff.toml index 5163767e..d6db6a4a 100644 --- a/modules/network/cliff.toml +++ b/modules/network/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/modules/scene/cliff.toml b/modules/scene/cliff.toml index 5163767e..d6db6a4a 100644 --- a/modules/scene/cliff.toml +++ b/modules/scene/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/modules/sound/cliff.toml b/modules/sound/cliff.toml index 5163767e..d6db6a4a 100644 --- a/modules/sound/cliff.toml +++ b/modules/sound/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/package.json b/package.json index 86affa18..c0d0e7be 100644 --- a/package.json +++ b/package.json @@ -34,7 +34,6 @@ "@commitlint/cli": "catalog:ci", "@commitlint/config-conventional": "catalog:ci", "@microsoft/api-extractor": "catalog:docs", - "@nanoforge-dev/actions": "catalog:ci", "@nanoforge-dev/utils-eslint-config": "workspace:*", "@nanoforge-dev/utils-prettier-config": "workspace:*", "@playwright/test": "catalog:test", diff --git a/packages/asset/cliff.toml b/packages/asset/cliff.toml index 5163767e..d6db6a4a 100644 --- a/packages/asset/cliff.toml +++ b/packages/asset/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/packages/common/cliff.toml b/packages/common/cliff.toml index 5163767e..d6db6a4a 100644 --- a/packages/common/cliff.toml +++ b/packages/common/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/packages/core/cliff.toml b/packages/core/cliff.toml index 5163767e..d6db6a4a 100644 --- a/packages/core/cliff.toml +++ b/packages/core/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/packages/env/cliff.toml b/packages/env/cliff.toml index 5163767e..d6db6a4a 100644 --- a/packages/env/cliff.toml +++ b/packages/env/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index db659c60..6fbc1cc8 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -123,9 +123,6 @@ catalogs: '@favware/cliff-jumper': specifier: ^6.0.0 version: 6.1.0 - '@nanoforge-dev/actions': - specifier: ^2.1.5 - version: 2.1.5 husky: specifier: ^9.1.7 version: 9.1.7 @@ -232,9 +229,6 @@ importers: '@microsoft/api-extractor': specifier: catalog:docs version: 7.59.0(@types/node@26.4.0) - '@nanoforge-dev/actions': - specifier: catalog:ci - version: 2.1.5 '@nanoforge-dev/utils-eslint-config': specifier: workspace:* version: link:utils/eslint-config @@ -1346,24 +1340,6 @@ importers: packages: - '@actions/core@3.0.1': - resolution: {integrity: sha512-a6d/Nwahm9fliVGRhdhofo40HjHQasUPusmc7vBfyky+7Z+P2A1J68zyFVaNcEclc/Se+eO595oAr5nwEIoIUA==} - - '@actions/exec@3.0.0': - resolution: {integrity: sha512-6xH/puSoNBXb72VPlZVm7vQ+svQpFyA96qdDBvhB8eNZOE8LtPf9L4oAsfzK/crCL8YZ+19fKYVnM63Sl+Xzlw==} - - '@actions/github@9.1.1': - resolution: {integrity: sha512-tL5JbYOBZHc0ngEnCsaDcryUizIUIlQyIMwy1Wkx93H5HzbBJ7TbiPx2PnFjBwZW0Vh05JmfFZhecE6gglYegA==} - - '@actions/http-client@3.0.2': - resolution: {integrity: sha512-JP38FYYpyqvUsz+Igqlc/JG6YO9PaKuvqjM3iGvaLqFnJ7TFmcLyy2IDrY0bI0qCQug8E9K+elv5ZNfw62ZJzA==} - - '@actions/http-client@4.0.1': - resolution: {integrity: sha512-+Nvd1ImaOZBSoPbsUtEhv+1z99H12xzncCkz0a3RuehINE81FZSe2QTj3uvAPTcJX/SCzUQHQ0D1GrPMbrPitg==} - - '@actions/io@3.0.2': - resolution: {integrity: sha512-nRBchcMM+QK1pdjO7/idu86rbJI5YHUKCvKs0KxnSYbVe3F51UfGxuZX4Qy/fWlp6l7gWFwIkrOzN+oUK03kfw==} - '@angular-devkit/core@22.1.8': resolution: {integrity: sha512-34lsgg2FwMVBX7nR/ZqzRUcdvdYPvSB8XAEr2GudXAyZwLI9ehzfQlagAWR/gEb8p4uCFZW0r7uU0toxydq4Rw==} engines: {node: ^22.22.3 || ^24.15.0 || >=26.0.0, npm: ^6.11.0 || ^7.5.6 || >=8.0.0, yarn: '>= 1.13.0'} @@ -1799,10 +1775,6 @@ packages: react: ^17.0.0 || ^18.0.0 react-dom: ^17.0.0 || ^18.0.0 - '@nanoforge-dev/actions@2.1.5': - resolution: {integrity: sha512-aXFw1PGS8NmSEGAIJ1g5X+0kAiaWYPOvxkLttmKR1qO95O17mcpkKXfTdoSIyFnqPF2YnZjq9KR7Cvs27fNewg==} - engines: {node: '25'} - '@nanoforge-dev/cli@2.3.0': resolution: {integrity: sha512-VVEodsvmLIIdQpwJ7KU/ei/q0Xupr/dhGqDDdc9QC9YnYg1KiSwbv9RD0ncFIUJU2O4kn+b4HIHKxp4e3n4gLQ==} engines: {node: '26'} @@ -1897,24 +1869,9 @@ packages: resolution: {integrity: sha512-5s15CCiY8XXQ+FG+b1YQcl6Z2FA++nwAz/tg2VUrTmnMncP+2nnGUEYANImdnxsA2Fnq+Mbl7hDjUTw7cFAwcg==} engines: {node: '>= 20'} - '@octokit/openapi-types@27.0.0': - resolution: {integrity: sha512-whrdktVs1h6gtR+09+QsNk2+FO+49j6ga1c55YZudfEG+oKJVvJLQi3zkOm5JjiUXAagWK2tI2kTGKJ2Ys7MGA==} - '@octokit/openapi-types@28.0.0': resolution: {integrity: sha512-0rFyLuyHvIj6uuZWuDslxkowFYdPXoNIkeAv4b27dzm2Tf4vGWXnPsMcxs7d65kLdMERgP3wc1AEPlqMz8e1cQ==} - '@octokit/plugin-paginate-rest@14.0.0': - resolution: {integrity: sha512-fNVRE7ufJiAA3XUrha2omTA39M6IXIc6GIZLvlbsm8QOQCYvpq/LkMNGyFlB1d8hTDzsAXa3OKtybdMAYsV/fw==} - engines: {node: '>= 20'} - peerDependencies: - '@octokit/core': '>=6' - - '@octokit/plugin-rest-endpoint-methods@17.0.0': - resolution: {integrity: sha512-B5yCyIlOJFPqUUeiD0cnBJwWJO8lkJs5d8+ze9QDP6SvfiXSz1BF+91+0MeI1d2yxgOhU/O+CvtiZ9jSkHhFAw==} - engines: {node: '>= 20'} - peerDependencies: - '@octokit/core': '>=6' - '@octokit/plugin-retry@8.1.1': resolution: {integrity: sha512-VCVvZ/R1+u3WuiBWpNavZ0mY4aaJNAsENrpBP9aLSR2QyOpQgd7DhM5j4AW7z4MQpnJYgwBPf0XqPQoNBRdQwg==} engines: {node: '>= 20'} @@ -1929,9 +1886,6 @@ packages: resolution: {integrity: sha512-3CBg9aJ0hO9Pjyij8LbK/xYtEaPws9SW7xKz67daPNxQB1q5Y9OMA7DDOG0A6Hwf9ygGu3tvzusg0LXQ8/wAjA==} engines: {node: '>= 20'} - '@octokit/types@16.0.0': - resolution: {integrity: sha512-sKq+9r1Mm4efXW1FCk7hFSeJo4QKreL/tTbR0rz/qx/r1Oa2VV83LTA/H/MuCOX7uCIJmQVRKBcbmWoySjAnSg==} - '@octokit/types@17.0.0': resolution: {integrity: sha512-ByP1v7YL5SMveFPP7+sj0/ZuWCOOg/Chs4NafOMpq6WNIM/hdGY0S7C0TCGDBWu1aGmOxmUIhMx3cO+IdwYZ1Q==} @@ -4217,10 +4171,6 @@ packages: tslib@2.8.1: resolution: {integrity: sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==} - tunnel@0.0.6: - resolution: {integrity: sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==} - engines: {node: '>=0.6.11 <=0.7.0 || >=0.7.3'} - turbo@2.10.12: resolution: {integrity: sha512-AswgMPnpOoaVZHrrSBejETzEbuIA69OVGwfkHwfrY0A23VjWXBANzgq9+OymWOHAIArB7D1+1z498WY8fGg1Jw==} hasBin: true @@ -4252,10 +4202,6 @@ packages: undici-types@8.3.0: resolution: {integrity: sha512-j375ScV60dom+YkPFIfTLcOiPxkN/buHz5GobjLhixFuANaNs3C9l4GmrWqejgXWJ7BbJcFYpTEUkS1Ge8bpZQ==} - undici@6.28.0: - resolution: {integrity: sha512-LIY910g9TI13YS95lrMFrs8Rm/u/irgHeTWoKCoteeJ04CUJ92eEfj0rVn+7VKMPBpUPiUoBKfhNyLI23EE/KA==} - engines: {node: '>=18.17'} - unicode-emoji-modifier-base@1.0.0: resolution: {integrity: sha512-yLSH4py7oFH3oG/9K+XWrz1pSi3dfUrWEnInbxMfArOfc1+33BlGPQtLsOYwvdMy11AwUBetYuaRxSPqgkq+8g==} engines: {node: '>=4'} @@ -4451,37 +4397,6 @@ packages: snapshots: - '@actions/core@3.0.1': - dependencies: - '@actions/exec': 3.0.0 - '@actions/http-client': 4.0.1 - - '@actions/exec@3.0.0': - dependencies: - '@actions/io': 3.0.2 - - '@actions/github@9.1.1': - dependencies: - '@actions/http-client': 3.0.2 - '@octokit/core': 7.0.7 - '@octokit/plugin-paginate-rest': 14.0.0(@octokit/core@7.0.7) - '@octokit/plugin-rest-endpoint-methods': 17.0.0(@octokit/core@7.0.7) - '@octokit/request': 10.0.15 - '@octokit/request-error': 7.1.1 - undici: 6.28.0 - - '@actions/http-client@3.0.2': - dependencies: - tunnel: 0.0.6 - undici: 6.28.0 - - '@actions/http-client@4.0.1': - dependencies: - tunnel: 0.0.6 - undici: 6.28.0 - - '@actions/io@3.0.2': {} - '@angular-devkit/core@22.1.8(chokidar@5.0.0)': dependencies: ajv: 8.20.0 @@ -4986,13 +4901,6 @@ snapshots: react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - '@nanoforge-dev/actions@2.1.5': - dependencies: - '@actions/core': 3.0.1 - '@actions/github': 9.1.1 - commander: 15.0.0 - semver: 7.8.5 - '@nanoforge-dev/cli@2.3.0(@types/node@26.4.0)(synckit@0.11.13)': dependencies: '@angular-devkit/schematics': 22.1.8(chokidar@5.0.0) @@ -5107,20 +5015,8 @@ snapshots: '@octokit/types': 17.0.0 universal-user-agent: 7.0.3 - '@octokit/openapi-types@27.0.0': {} - '@octokit/openapi-types@28.0.0': {} - '@octokit/plugin-paginate-rest@14.0.0(@octokit/core@7.0.7)': - dependencies: - '@octokit/core': 7.0.7 - '@octokit/types': 16.0.0 - - '@octokit/plugin-rest-endpoint-methods@17.0.0(@octokit/core@7.0.7)': - dependencies: - '@octokit/core': 7.0.7 - '@octokit/types': 16.0.0 - '@octokit/plugin-retry@8.1.1(@octokit/core@7.0.7)': dependencies: '@octokit/core': 7.0.7 @@ -5141,10 +5037,6 @@ snapshots: json-with-bigint: 3.5.12 universal-user-agent: 7.0.3 - '@octokit/types@16.0.0': - dependencies: - '@octokit/openapi-types': 27.0.0 - '@octokit/types@17.0.0': dependencies: '@octokit/openapi-types': 28.0.0 @@ -7138,8 +7030,6 @@ snapshots: tslib@2.8.1: {} - tunnel@0.0.6: {} - turbo@2.10.12: optionalDependencies: '@turbo/darwin-64': 2.10.12 @@ -7175,8 +7065,6 @@ snapshots: undici-types@8.3.0: {} - undici@6.28.0: {} - unicode-emoji-modifier-base@1.0.0: {} unicorn-magic@0.3.0: {} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml index 832bb414..21a87c62 100644 --- a/pnpm-workspace.yaml +++ b/pnpm-workspace.yaml @@ -21,7 +21,6 @@ catalogs: '@commitlint/cli': ^21.2.2 '@commitlint/config-conventional': ^21.2.2 '@favware/cliff-jumper': ^6.0.0 - '@nanoforge-dev/actions': ^2.1.5 husky: ^9.1.7 lint-staged: ^17.4.1 config: diff --git a/utils/eslint-config/cliff.toml b/utils/eslint-config/cliff.toml index 89c78902..6eda5fe4 100644 --- a/utils/eslint-config/cliff.toml +++ b/utils/eslint-config/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"}, diff --git a/utils/prettier-config/cliff.toml b/utils/prettier-config/cliff.toml index d6ba2f1c..9e6cc651 100644 --- a/utils/prettier-config/cliff.toml +++ b/utils/prettier-config/cliff.toml @@ -32,7 +32,7 @@ body = """ {% if commit.breaking %}\ {% for footer in commit.footers %}\ {% if footer.breaking %}\ - \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value }}\ + \n{% raw %} {% endraw %}- **{{ footer.token }}{{ footer.separator }}** {{ footer.value | split(pat="\n\n") | first | replace(from="\n", to=" ") }}\ {% endif %}\ {% endfor %}\ {% endif %}\ @@ -52,6 +52,7 @@ footer = "" conventional_commits = true filter_unconventional = true commit_parsers = [ + { field = "breaking", pattern = "true", group = "Breaking Changes"}, { message = "^feat", group = "Features"}, { message = "^fix", group = "Bug Fixes"}, { message = "^docs", group = "Documentation"},