mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 15:24:05 +00:00
commit
1821cd05f2
16
.github/workflows/Release-all.yml
vendored
16
.github/workflows/Release-all.yml
vendored
|
@ -141,35 +141,31 @@ jobs:
|
||||||
id: shortSHA
|
id: shortSHA
|
||||||
run: |
|
run: |
|
||||||
echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
|
echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
|
||||||
- name: Get changelog tags
|
- name: Get previous tag
|
||||||
id: changelogTags
|
id: changelogTags
|
||||||
run: |
|
run: |
|
||||||
if [[ '${{env.prerelease}}' == 'true' ]]
|
if [[ '${{env.prerelease}}' == 'true' ]]
|
||||||
then
|
then
|
||||||
echo "This is a pre-release"
|
echo "This is a pre-release"
|
||||||
previousTag=$(git tag --sort=-creatordate | grep "^v" | sed -n 2p)
|
previousTag=$(git tag --sort=-creatordate | grep "^v" | head -n 1)
|
||||||
currentTag=$(git tag --sort=-creatordate | grep "^v" | sed -n 1p)
|
|
||||||
else
|
else
|
||||||
echo "This is not a pre-release"
|
echo "This is not a pre-release"
|
||||||
previousTag=$(git tag --sort=-creatordate | grep "^v" | grep -v "alpha" | sed -n 2p)
|
previousTag=$(git tag --sort=-creatordate | grep "^v" | grep -v "alpha" | head -n 1)
|
||||||
currentTag=$(git tag --sort=-creatordate | grep "^v" | grep -v "alpha" | sed -n 1p)
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "prev_tag=$previousTag" >> $GITHUB_OUTPUT
|
echo "prev_tag=$previousTag" >> $GITHUB_OUTPUT
|
||||||
echo "curr_tag=$currentTag" >> $GITHUB_OUTPUT
|
|
||||||
echo "previousTag : $previousTag"
|
echo "previousTag : $previousTag"
|
||||||
echo "currentTag : $currentTag"
|
|
||||||
- name: Get new tag
|
- name: Get new tag
|
||||||
id: getNewTag
|
id: getNewTag
|
||||||
run: |
|
run: |
|
||||||
echo "newTag=v${{ env.version }}-${{ env.versionSuffix }}.${{ steps.shortSHA.outputs.sha_short }}" >> $GITHUB_OUTPUT
|
echo "newTag=v${{ env.version }}-${{ env.versionSuffix }}.${{ steps.shortSHA.outputs.sha_short }}" >> $GITHUB_OUTPUT
|
||||||
- name: Build Changelog
|
- name: Build Changelog
|
||||||
id: build_changelog
|
id: build_changelog
|
||||||
uses: mikepenz/release-changelog-builder-action@v3
|
uses: mikepenz/release-changelog-builder-action@v5
|
||||||
with:
|
with:
|
||||||
commitMode: false
|
commitMode: false
|
||||||
fromTag: ${{ steps.changelogTags.outputs.prev_tag }}
|
fromTag: ${{ steps.changelogTags.outputs.prev_tag }}
|
||||||
toTag: "${{ steps.changelogTags.outputs.curr_tag }}"
|
toTag: ${{ github.sha }}
|
||||||
configurationJson: |
|
configurationJson: |
|
||||||
{
|
{
|
||||||
"template": "#{{CHANGELOG}}\n\n<details>\n<summary>🔴 Uncategorized</summary>\n\n#{{UNCATEGORIZED}}\n</details>",
|
"template": "#{{CHANGELOG}}\n\n<details>\n<summary>🔴 Uncategorized</summary>\n\n#{{UNCATEGORIZED}}\n</details>",
|
||||||
|
@ -232,7 +228,7 @@ jobs:
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
retention-days: 7
|
retention-days: 7
|
||||||
path: ./changelog.txt
|
path: ./changelog.txt
|
||||||
|
|
||||||
publish:
|
publish:
|
||||||
needs: [build_macOS, build_Windows, generate_other_staffs]
|
needs: [build_macOS, build_Windows, generate_other_staffs]
|
||||||
runs-on: ubuntu-24.04
|
runs-on: ubuntu-24.04
|
||||||
|
|
Loading…
Reference in a new issue