mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 19:24:08 +00:00
github:add 6.2 support
seperate autotag into an alone workflow. other os's workflow dependent on it
This commit is contained in:
parent
c6cb59af3f
commit
d24904ece8
3
.github/workflows/macos copy.yml
vendored
3
.github/workflows/macos copy.yml
vendored
|
@ -36,6 +36,7 @@ jobs:
|
|||
qt_arch: [clang_64]
|
||||
env:
|
||||
targetName: GoldenDict
|
||||
version: 22.2.alpha
|
||||
steps:
|
||||
# macos 11.0 默认环境变了,要指定
|
||||
- name: prepare env
|
||||
|
@ -86,7 +87,7 @@ jobs:
|
|||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
file: ${{ env.targetName }}.dmg
|
||||
asset_name: ${{ env.targetName }}-M1_${{ matrix.os }}_${{ matrix.qt_ver }}_${{ steps.vars.outputs.sha_short }}.dmg
|
||||
tag: v${{ steps.autotag.outputs.version }}-${{ steps.vars.outputs.sha_short }}
|
||||
tag: v${{env.version}}-${{ steps.vars.outputs.sha_short }}
|
||||
overwrite: true
|
||||
release_name: win-ubuntu-macos-${{ github.ref_name }}-${{steps.vars.outputs.release_date}}
|
||||
prerelease: true
|
||||
|
|
11
.github/workflows/macos-6.2.yml
vendored
11
.github/workflows/macos-6.2.yml
vendored
|
@ -56,7 +56,7 @@ jobs:
|
|||
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 1
|
||||
fetch-depth: 0
|
||||
- name: Set outputs
|
||||
id: githash
|
||||
run: |
|
||||
|
@ -82,8 +82,11 @@ jobs:
|
|||
previousTag=$(git tag --sort=-creatordate | sed -n 2p)
|
||||
echo "previousTag : $previousTag"
|
||||
|
||||
commitSummary="$(git shortlog $previousTag..HEAD)"
|
||||
echo "::set-output name=COMMIT_SUMMARY::\"$commitSummary\""
|
||||
CHANGELOG="$(git shortlog $previousTag..HEAD)"
|
||||
CHANGELOG="${CHANGELOG//'%'/'%25'}"
|
||||
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
|
||||
CHANGELOG="${CHANGELOG//$'\r'/'%0D'}"
|
||||
echo "::set-output name=COMMIT_SUMMARY::$(echo "$CHANGELOG")"
|
||||
# tag 上传Release
|
||||
- name: uploadRelease
|
||||
uses: svenstaro/upload-release-action@v2
|
||||
|
@ -91,7 +94,7 @@ jobs:
|
|||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
file: ${{ env.targetName }}.dmg
|
||||
asset_name: ${{ matrix.qt_ver }}-${{ env.targetName }}_${{ matrix.os }}_${{ steps.vars.outputs.sha_short }}.dmg
|
||||
tag: v${{ steps.autotag.outputs.version }}-${{ steps.vars.outputs.sha_short }}
|
||||
tag: v${{env.version}}-${{ steps.vars.outputs.sha_short }}
|
||||
overwrite: true
|
||||
release_name: win-ubuntu-macos-${{ github.ref_name }}-${{steps.vars.outputs.release_date}}
|
||||
prerelease: true
|
||||
|
|
54
.github/workflows/macos.yml
vendored
54
.github/workflows/macos.yml
vendored
|
@ -3,28 +3,31 @@ concurrency:
|
|||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
on:
|
||||
workflow_run:
|
||||
workflows: [AutoTag]
|
||||
types: [completed]
|
||||
workflow_dispatch:
|
||||
push:
|
||||
branches:
|
||||
- dev
|
||||
- master
|
||||
# - staged
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- ".github/**"
|
||||
- "howto/**"
|
||||
- "*.md"
|
||||
- ".clang-format"
|
||||
pull_request:
|
||||
branches:
|
||||
- dev
|
||||
- master
|
||||
# - staged
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- ".github/**"
|
||||
- "howto/**"
|
||||
- "*.md"
|
||||
# push:
|
||||
# branches:
|
||||
# - dev
|
||||
# - master
|
||||
# # - staged
|
||||
# paths-ignore:
|
||||
# - 'docs/**'
|
||||
# - ".github/**"
|
||||
# - "howto/**"
|
||||
# - "*.md"
|
||||
# - ".clang-format"
|
||||
# pull_request:
|
||||
# branches:
|
||||
# - dev
|
||||
# - master
|
||||
# # - staged
|
||||
# paths-ignore:
|
||||
# - 'docs/**'
|
||||
# - ".github/**"
|
||||
# - "howto/**"
|
||||
# - "*.md"
|
||||
jobs:
|
||||
build:
|
||||
name: Build
|
||||
|
@ -61,12 +64,7 @@ jobs:
|
|||
id: githash
|
||||
run: |
|
||||
echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
|
||||
- uses: Klemensas/action-autotag@stable
|
||||
id: autotag
|
||||
with:
|
||||
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
|
||||
tag_prefix: "v"
|
||||
tag_suffix: "-${{ steps.githash.outputs.sha_short }}"
|
||||
|
||||
|
||||
- name: build macos
|
||||
run: |
|
||||
|
@ -101,7 +99,7 @@ jobs:
|
|||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
file: ${{ env.targetName }}.dmg
|
||||
asset_name: ${{ matrix.qt_ver }}-${{ env.targetName }}_${{ matrix.os }}_${{ steps.vars.outputs.sha_short }}.dmg
|
||||
tag: v${{ steps.autotag.outputs.version }}-${{ steps.vars.outputs.sha_short }}
|
||||
tag: v${{env.version}}-${{ steps.vars.outputs.sha_short }}
|
||||
overwrite: true
|
||||
release_name: win-ubuntu-macos-${{ github.ref_name }}-${{steps.vars.outputs.release_date}}
|
||||
prerelease: true
|
||||
|
|
11
.github/workflows/ubuntu-6.2.yml
vendored
11
.github/workflows/ubuntu-6.2.yml
vendored
|
@ -65,7 +65,7 @@ jobs:
|
|||
cd ..
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 1
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Set outputs
|
||||
id: githash
|
||||
|
@ -106,8 +106,11 @@ jobs:
|
|||
previousTag=$(git tag --sort=-creatordate | sed -n 2p)
|
||||
echo "previousTag : $previousTag"
|
||||
|
||||
commitSummary="$(git shortlog $previousTag..HEAD)"
|
||||
echo "::set-output name=COMMIT_SUMMARY::\"$commitSummary\""
|
||||
CHANGELOG="$(git shortlog $previousTag..HEAD)"
|
||||
CHANGELOG="${CHANGELOG//'%'/'%25'}"
|
||||
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
|
||||
CHANGELOG="${CHANGELOG//$'\r'/'%0D'}"
|
||||
echo "::set-output name=COMMIT_SUMMARY::$(echo "$CHANGELOG")"
|
||||
- name: uploadRelease
|
||||
# if: startsWith(github.event.ref, 'refs/tags/')
|
||||
uses: svenstaro/upload-release-action@v2
|
||||
|
@ -115,7 +118,7 @@ jobs:
|
|||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
file: ${{ steps.vars.outputs.appname }}
|
||||
asset_name: ${{ matrix.qt_ver }}-${{ steps.vars.outputs.appname }}
|
||||
tag: v${{ steps.autotag.outputs.version }}-${{ steps.vars.outputs.sha_short }}
|
||||
tag: v${{env.version}}-${{ steps.vars.outputs.sha_short }}
|
||||
overwrite: true
|
||||
release_name: win-ubuntu-macos-${{ github.ref_name }}-${{steps.vars.outputs.release_date}}
|
||||
prerelease: true
|
||||
|
|
59
.github/workflows/ubuntu.yml
vendored
59
.github/workflows/ubuntu.yml
vendored
|
@ -4,28 +4,31 @@ concurrency:
|
|||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
on:
|
||||
workflow_run:
|
||||
workflows: [AutoTag]
|
||||
types: [completed]
|
||||
workflow_dispatch:
|
||||
push:
|
||||
branches:
|
||||
- dev
|
||||
- master
|
||||
# - staged
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- ".github/**"
|
||||
- "howto/**"
|
||||
- "*.md"
|
||||
- ".clang-format"
|
||||
pull_request:
|
||||
branches:
|
||||
- dev
|
||||
- master
|
||||
# - staged
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- ".github/**"
|
||||
- "howto/**"
|
||||
- "*.md"
|
||||
# push:
|
||||
# branches:
|
||||
# - dev
|
||||
# - master
|
||||
# # - staged
|
||||
# paths-ignore:
|
||||
# - 'docs/**'
|
||||
# - ".github/**"
|
||||
# - "howto/**"
|
||||
# - "*.md"
|
||||
# - ".clang-format"
|
||||
# pull_request:
|
||||
# branches:
|
||||
# - dev
|
||||
# - master
|
||||
# # - staged
|
||||
# paths-ignore:
|
||||
# - 'docs/**'
|
||||
# - ".github/**"
|
||||
# - "howto/**"
|
||||
# - "*.md"
|
||||
jobs:
|
||||
build:
|
||||
name: Build
|
||||
|
@ -62,12 +65,12 @@ jobs:
|
|||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- run: |
|
||||
short_sha=$(git rev-parse --short HEAD)
|
||||
tagname=v$version-$short_sha
|
||||
echo $tagname
|
||||
git tag $tagname -f
|
||||
git push origin $tagname
|
||||
# - run: |
|
||||
# short_sha=$(git rev-parse --short HEAD)
|
||||
# tagname=v$version-$short_sha
|
||||
# echo $tagname
|
||||
# git tag $tagname -f
|
||||
# git push origin $tagname
|
||||
|
||||
- name: Set git short sha
|
||||
id: githash
|
||||
|
@ -111,7 +114,7 @@ jobs:
|
|||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
file: ${{ steps.vars.outputs.appname }}
|
||||
asset_name: ${{ matrix.qt_ver }}-${{ steps.vars.outputs.appname }}
|
||||
tag: v$version-${{ steps.vars.outputs.sha_short }}
|
||||
tag: v${{env.version}}-${{ steps.vars.outputs.sha_short }}
|
||||
overwrite: true
|
||||
release_name: win-ubuntu-macos-${{ github.ref_name }}-${{steps.vars.outputs.release_date}}
|
||||
prerelease: true
|
||||
|
|
13
.github/workflows/windows-6.2.yml
vendored
13
.github/workflows/windows-6.2.yml
vendored
|
@ -71,7 +71,7 @@ jobs:
|
|||
# 拉取代码
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 1
|
||||
fetch-depth: 0
|
||||
- name: Set outputs
|
||||
id: githash
|
||||
run: |
|
||||
|
@ -95,8 +95,11 @@ jobs:
|
|||
previousTag=$(git tag --sort=-creatordate | sed -n 2p)
|
||||
echo "previousTag : $previousTag"
|
||||
|
||||
commitSummary="$(git shortlog $previousTag..HEAD)"
|
||||
echo "::set-output name=COMMIT_SUMMARY::\"$commitSummary\""
|
||||
CHANGELOG="$(git shortlog $previousTag..HEAD)"
|
||||
CHANGELOG="${CHANGELOG//'%'/'%25'}"
|
||||
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
|
||||
CHANGELOG="${CHANGELOG//$'\r'/'%0D'}"
|
||||
echo "::set-output name=COMMIT_SUMMARY::$(echo "$CHANGELOG")"
|
||||
|
||||
# msvc编译
|
||||
- uses: ilammy/msvc-dev-cmd@v1
|
||||
|
@ -141,7 +144,7 @@ jobs:
|
|||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
file: ${{ steps.package.outputs.packageName }}.zip
|
||||
asset_name: ${{ matrix.qt_ver }}-${{ steps.package.outputs.packageName }}.zip
|
||||
tag: v${{ steps.autotag.outputs.version }}-${{ steps.vars.outputs.sha_short }}
|
||||
tag: v${{env.version}}-${{ steps.vars.outputs.sha_short }}
|
||||
overwrite: true
|
||||
release_name: win-ubuntu-macos-${{ github.ref_name }}-${{steps.vars.outputs.release_date}}
|
||||
prerelease: true
|
||||
|
@ -161,7 +164,7 @@ jobs:
|
|||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
file: release/${{ env.targetName }}
|
||||
asset_name: ${{ matrix.qt_ver }}-${{ env.targetName }}
|
||||
tag: v${{ steps.autotag.outputs.version }}-${{ steps.vars.outputs.sha_short }}
|
||||
tag: v${{env.version}}-${{ steps.vars.outputs.sha_short }}
|
||||
overwrite: true
|
||||
release_name: win-ubuntu-macos-${{ github.ref_name }}-${{steps.vars.outputs.release_date}}
|
||||
prerelease: true
|
||||
|
|
56
.github/workflows/windows.yml
vendored
56
.github/workflows/windows.yml
vendored
|
@ -3,29 +3,32 @@ concurrency:
|
|||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
on:
|
||||
workflow_run:
|
||||
workflows: [AutoTag]
|
||||
types: [completed]
|
||||
workflow_dispatch:
|
||||
# push代码时触发workflow
|
||||
push:
|
||||
branches:
|
||||
- dev
|
||||
- master
|
||||
# - staged
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- ".github/**"
|
||||
- "howto/**"
|
||||
- "*.md"
|
||||
- ".clang-format"
|
||||
pull_request:
|
||||
branches:
|
||||
- dev
|
||||
- master
|
||||
# - staged
|
||||
paths-ignore:
|
||||
- 'docs/**'
|
||||
- ".github/**"
|
||||
- "howto/**"
|
||||
- "*.md"
|
||||
# push:
|
||||
# branches:
|
||||
# - dev
|
||||
# - master
|
||||
# # - staged
|
||||
# paths-ignore:
|
||||
# - 'docs/**'
|
||||
# - ".github/**"
|
||||
# - "howto/**"
|
||||
# - "*.md"
|
||||
# - ".clang-format"
|
||||
# pull_request:
|
||||
# branches:
|
||||
# - dev
|
||||
# - master
|
||||
# # - staged
|
||||
# paths-ignore:
|
||||
# - 'docs/**'
|
||||
# - ".github/**"
|
||||
# - "howto/**"
|
||||
# - "*.md"
|
||||
jobs:
|
||||
build:
|
||||
name: Build
|
||||
|
@ -72,12 +75,7 @@ jobs:
|
|||
id: githash
|
||||
run: |
|
||||
echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
|
||||
- uses: Klemensas/action-autotag@stable
|
||||
id: autotag
|
||||
with:
|
||||
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
|
||||
tag_prefix: "v"
|
||||
tag_suffix: "-${{ steps.githash.outputs.sha_short }}"
|
||||
|
||||
- name: Set outputs
|
||||
id: vars
|
||||
shell: bash
|
||||
|
@ -135,7 +133,7 @@ jobs:
|
|||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
file: ${{ steps.package.outputs.packageName }}.zip
|
||||
asset_name: ${{ matrix.qt_ver }}-${{ steps.package.outputs.packageName }}.zip
|
||||
tag: v${{ steps.autotag.outputs.version }}-${{ steps.vars.outputs.sha_short }}
|
||||
tag: v${{env.version}}-${{ steps.vars.outputs.sha_short }}
|
||||
overwrite: true
|
||||
release_name: win-ubuntu-macos-${{ github.ref_name }}-${{steps.vars.outputs.release_date}}
|
||||
prerelease: true
|
||||
|
@ -160,7 +158,7 @@ jobs:
|
|||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
file: release/${{ env.targetName }}
|
||||
asset_name: ${{ matrix.qt_ver }}-${{ env.targetName }}
|
||||
tag: v${{ steps.autotag.outputs.version }}-${{ steps.vars.outputs.sha_short }}
|
||||
tag: v${{env.version}}-${{ steps.vars.outputs.sha_short }}
|
||||
overwrite: true
|
||||
release_name: win-ubuntu-macos-${{ github.ref_name }}-${{steps.vars.outputs.release_date}}
|
||||
prerelease: true
|
||||
|
|
Loading…
Reference in a new issue