Skip to content

Commit

Permalink
fix: correct readme, updates workflow release, correct tag settings f…
Browse files Browse the repository at this point in the history
…or changelog generation
  • Loading branch information
pfandie committed Apr 14, 2023
1 parent 987cb92 commit d1d67e0
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .chglog/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ style: github
template: CHANGELOG.tpl.md
info:
title: CHANGELOG
repository_url: https://github.com/pfandie/gha-generate-changelog
repository_url: https://github.com/pfandie/generate-changelog-action
options:
tag_filter_pattern: '^v'
sort: "date"
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ jobs:
- name: Generate Changelog
uses: ./
id: changelog
with:
next_tag: ${{ github.ref_name }}

- name: Create Release
uses: ncipollo/release-action@a2e71bdd4e7dab70ca26a852f29600c98b33153e # v1.12.0
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
steps:
- uses: pfandie/generate-changelog-action@v1
with:
next_version: "${{ github.ref_name }}"
next_tag: "${{ github.ref_name }}"
```
### Generate CHANGELOG on `push` to `release` branches with previous tag
Expand Down
4 changes: 2 additions & 2 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ fi
# Check if OLD_TAG input is set
if [[ -n "$INPUT_NEXT_TAG" && -n "$INPUT_OLD_TAG" ]]; then
echo "ℹ️ Set old Tag to $INPUT_OLD_TAG"
next_tag="$INPUT_NEXT_TAG..$INPUT_OLD_TAG"
next_tag="$INPUT_OLD_TAG..$INPUT_NEXT_TAG"
fi

# Set Output file
Expand All @@ -25,7 +25,7 @@ git config --global --add safe.directory "${GITHUB_WORKSPACE}"

# Generate CHANGELOG based on settings
echo "🔖 Generating CHANGELOG"
echo "command: /usr/local/bin/git-chglog -c '$INPUT_CONFIG_PATH/config.yml' '$next_tag' '$output_file')"
echo "command: /usr/local/bin/git-chglog -c \"$INPUT_CONFIG_PATH/config.yml\" \"$next_tag\" \"$output_file\")"
changelog=$(/usr/local/bin/git-chglog -c "${INPUT_CONFIG_PATH}/config.yml" "$next_tag" "$output_file")

# Print CHANGELOG to stdout
Expand Down

0 comments on commit d1d67e0

Please sign in to comment.