From c8865b254ce399e1950f0da982b3ac9e093f732b Mon Sep 17 00:00:00 2001 From: Conventional Changelog Action Date: Sat, 24 Feb 2024 14:33:03 +0000 Subject: [PATCH] feat: Support multiple git-path config option --- .github/workflows/test.yml | 34 ++++++++++++++++++++++++++++++++++ CHANGELOG.md | 18 +++++++++--------- dist/index.js | 2 +- package-lock.json | 4 ++-- package.json | 2 +- src/index.js | 2 +- 6 files changed, 48 insertions(+), 14 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d07d7f99..97eebb9d 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1076,3 +1076,37 @@ jobs: env: OUTPUT_FILE: "CHANGELOG.md" EXPECTED_FILE: "test-input-file.md" + + test-multiple-git-path: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + with: + path: "./" + ref: ${{ github.ref == 'github.event.repository.default_branch' && github.head_ref || github.event.pull_request.head.ref }} + fetch-depth: 0 + + - run: npm ci --prod + - run: npm run build + + - name: Generate changelog + id: changelog + uses: ./ + with: + github-token: ${{ secrets.github_token }} + git-branch: ${{ github.ref == github.event.repository.default_branch && github.head_ref || github.event.pull_request.head.ref }} + git-path: | + src/helpers + src/version + .github/workflows + skip-commit: 'true' + skip-tag: 'true' + release-count: 0 + create-summary: 'true' + + - name: Test output + run: | + echo "${{ steps.changelog.outputs.changelog }}" > change_log + sed "s/\(### \)\(.*\)/*\2*/g" change_log > change_log2 + diff change_log change_log2 > /dev/null && echo "The changelog has not been generated." || echo "The changelog has been generated." \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 4bd4ea6d..0efe681a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,12 @@ +## [5.2.1](https://github.com/TriPSs/conventional-changelog-action/compare/v5.2.0...v5.2.1) (2024-02-24) + + +### Bug Fixes + +* support git-path config option for version bump ([e3346a2](https://github.com/TriPSs/conventional-changelog-action/commit/e3346a2be870347e11d3186035c42d3095bc0d8f)) + + + # [5.2.0](https://github.com/TriPSs/conventional-changelog-action/compare/v5.1.0...v5.2.0) (2024-02-07) @@ -42,12 +51,3 @@ -# [4.1.0](https://github.com/TriPSs/conventional-changelog-action/compare/v4.0.0...v4.1.0) (2023-09-21) - - -### Features - -* elixir support ([e669b12](https://github.com/TriPSs/conventional-changelog-action/commit/e669b12b9395bcb967ca5674c03ed7d6364ce675)) - - - diff --git a/dist/index.js b/dist/index.js index 5c6963c3..18e2d162 100644 --- a/dist/index.js +++ b/dist/index.js @@ -34828,7 +34828,7 @@ async function run() { const conventionalConfigFile = core.getInput('config-file-path') const preChangelogGenerationFile = core.getInput('pre-changelog-generation') const gitUrl = core.getInput('git-url') - const gitPath = core.getInput('git-path') + const gitPath = core.getMultilineInput('git-path') const infile = core.getInput('input-file') const skipCi = core.getBooleanInput('skip-ci') const createSummary = core.getBooleanInput('create-summary') diff --git a/package-lock.json b/package-lock.json index 2e01e443..73167dab 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "conventional-changelog-action", - "version": "5.1.0", + "version": "5.2.1", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "conventional-changelog-action", - "version": "5.1.0", + "version": "5.2.1", "license": "MIT", "dependencies": { "@actions/core": "^1.10.1", diff --git a/package.json b/package.json index 64b5b385..c177f498 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "conventional-changelog-action", - "version": "5.2.0", + "version": "5.2.1", "description": "Github Action that generates a changelog with the Conventional Changelog CLI", "keywords": [ "actions", diff --git a/src/index.js b/src/index.js index 722392b8..7e8bd836 100644 --- a/src/index.js +++ b/src/index.js @@ -48,7 +48,7 @@ async function run() { const conventionalConfigFile = core.getInput('config-file-path') const preChangelogGenerationFile = core.getInput('pre-changelog-generation') const gitUrl = core.getInput('git-url') - const gitPath = core.getInput('git-path') + const gitPath = core.getMultilineInput('git-path') const infile = core.getInput('input-file') const skipCi = core.getBooleanInput('skip-ci') const createSummary = core.getBooleanInput('create-summary')