diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ef07cd0..a7622f1 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -19,6 +19,23 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 - - uses: ./ + - name: "Minimal Configuration" + id: minimal_release + uses: ./ + + - name: Echo Minimal + run: echo ${{steps.minimal_release.outputs.changelog}} + + - name: "Complex Configuration" + id: complex_release + uses: ./ with: - milliseconds: 1000 + configuration: "configuration_complex.json" + owner: "mikepenz" + repo: "release-changelog-builder-action" + fromTag: "0.0.1" + toTag: "0.0.2" + + - name: Echo Complex + run: echo ${{steps.complex_release.outputs.changelog}} + diff --git a/action.yml b/action.yml index 1faf166..922478d 100644 --- a/action.yml +++ b/action.yml @@ -5,6 +5,7 @@ inputs: configuration: required: true description: 'path to the configuration file' + default: "configuration.json" path: description: 'the path to runt his action in' owner: diff --git a/configuration.json b/configuration.json index d000086..a36a739 100644 --- a/configuration.json +++ b/configuration.json @@ -18,13 +18,7 @@ } ], "sort": "ASC", - "template": "${{CHANGELOG}}\n\n
\nUncategorized\n\n${{UNCATEGORIZED}}\n
", + "template": "${{CHANGELOG}}", "pr_template": "- ${{TITLE}}\n - PR: #${{NUMBER}}", - "empty_template": "- no changes", - "transformers": [ - { - "pattern": "[\\-\\*] (\\[(...|TEST|CI|SKIP)\\])( )?(.+?)\n(.+?[\\-\\*] )(.+)", - "target": "- $4\n - $6" - } - ] + "empty_template": "- no changes" } \ No newline at end of file diff --git a/configuration_complex.json b/configuration_complex.json new file mode 100644 index 0000000..d000086 --- /dev/null +++ b/configuration_complex.json @@ -0,0 +1,30 @@ +{ + "categories": [ + { + "title": "## ๐Ÿš€ Features", + "labels": ["feature"] + }, + { + "title": "## ๐Ÿฆ„ Internal Features", + "labels": ["internal"] + }, + { + "title": "## ๐Ÿ› Fixes", + "labels": ["fix"] + }, + { + "title": "## ๐Ÿงช Tests", + "labels": ["test"] + } + ], + "sort": "ASC", + "template": "${{CHANGELOG}}\n\n
\nUncategorized\n\n${{UNCATEGORIZED}}\n
", + "pr_template": "- ${{TITLE}}\n - PR: #${{NUMBER}}", + "empty_template": "- no changes", + "transformers": [ + { + "pattern": "[\\-\\*] (\\[(...|TEST|CI|SKIP)\\])( )?(.+?)\n(.+?[\\-\\*] )(.+)", + "target": "- $4\n - $6" + } + ] +} \ No newline at end of file