-
-
Notifications
You must be signed in to change notification settings - Fork 13
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tested this whole workflow and it works correctly 🎉
https://github.com/fregante/daily-version-action/runs/1114007888?check_suite_focus=true
https://github.com/fregante/daily-version-action/releases/tag/v1.2.1
Notice:
- v1.2.1 was created as requested
- v1 was updated
- The range link was wrong as expected (
v1..v1.2.1
instead ofv1.2.0..v1.2.1
), but in my private tests it seemed correct, so it probably depends on the order of tags. It can be disabled later if it actually doesn't work. exclude
(Addexclude
parameter #10) works correctly 🥳- Empty releases are correctly marked as Maintenance release
workflow_dispatch: | ||
inputs: | ||
Version: | ||
description: 'Example: v1.2.3' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 50 | ||
- uses: notlmn/release-with-changelog@v1 | ||
- run: git tag ${{ github.event.inputs.Version }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This creates the supplied tag
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
exclude: '^Meta' | ||
- name: Update major tag | ||
run: | | ||
MAJOR=$(echo ${{ github.event.inputs.Version }} | sed 's/\..*//') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sed
drops everything after the first dot, turning v1.2.3
into v1
This is why I removed running this action on itself, because we'd be constantly re-pushing tags. Also we should change range from |
Co-authored-by: Laxman <[email protected]>
Indeed that’s what’s happening. I was thinking we could just change the order of tags, but that doesn’t solve it. I’ll open another PR Regarding the triple dot, I don’t think that changes the output log, it just changes the way diffs are computed (in some cases). GitHub only uses double dots |
Ah yeah, I confused the 2. Let’s use the 3 dot |
Fixes fregante/daily-version-action#15
Considering that:
release-with-changelog
will fail if a Release exists: Improve documentation #2 (comment)I moved the auto-changelog workflow to the
workflow_dispatch
method.