Combine 2 ci pipeline pre-release and nightly into one for correcting build number nightly
This commit is contained in:
parent
9f71ec2dd7
commit
f73e7388e2
26
.github/workflows/jan-electron-build-nightly.yml
vendored
26
.github/workflows/jan-electron-build-nightly.yml
vendored
@ -1,6 +1,9 @@
|
|||||||
name: Jan Build Electron App Nightly or Manual
|
name: Jan Build Electron App Nightly or Manual
|
||||||
|
|
||||||
on:
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '0 20 * * 2,3,4' # At 8 PM UTC on Tuesday, Wednesday, and Thursday, which is 3 AM UTC+7
|
- cron: '0 20 * * 2,3,4' # At 8 PM UTC on Tuesday, Wednesday, and Thursday, which is 3 AM UTC+7
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
@ -27,8 +30,16 @@ jobs:
|
|||||||
echo "::set-output name=public_provider::${{ github.event.inputs.public_provider }}"
|
echo "::set-output name=public_provider::${{ github.event.inputs.public_provider }}"
|
||||||
echo "::set-output name=ref::${{ github.ref }}"
|
echo "::set-output name=ref::${{ github.ref }}"
|
||||||
else
|
else
|
||||||
echo "::set-output name=public_provider::cloudflare-r2"
|
if [ ${{ github.event_name == 'schedule' }} ]; then
|
||||||
echo "::set-output name=ref::refs/heads/dev"
|
echo "::set-output name=public_provider::cloudflare-r2"
|
||||||
|
echo "::set-output name=ref::refs/heads/dev"
|
||||||
|
else if [ ${{ github.event_name == 'push' }} ]; then
|
||||||
|
echo "::set-output name=public_provider::cloudflare-r2"
|
||||||
|
echo "::set-output name=ref::${{ github.ref }}"
|
||||||
|
else
|
||||||
|
echo "::set-output name=public_provider::none"
|
||||||
|
echo "::set-output name=ref::${{ github.ref }}"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
# Job create Update app version based on latest release tag with build number and save to output
|
# Job create Update app version based on latest release tag with build number and save to output
|
||||||
get-update-version:
|
get-update-version:
|
||||||
@ -73,6 +84,17 @@ jobs:
|
|||||||
push_to_branch: dev
|
push_to_branch: dev
|
||||||
new_version: ${{ needs.get-update-version.outputs.new_version }}
|
new_version: ${{ needs.get-update-version.outputs.new_version }}
|
||||||
|
|
||||||
|
noti-discord-pre-release-and-update-url-readme:
|
||||||
|
needs: [build-macos, build-windows-x64, build-linux-x64, get-update-version, set-public-provider]
|
||||||
|
secrets: inherit
|
||||||
|
if: github.event_name == 'push'
|
||||||
|
uses: ./.github/workflows/template-noti-discord-and-update-url-readme.yml
|
||||||
|
with:
|
||||||
|
ref: refs/heads/dev
|
||||||
|
build_reason: Pre-release
|
||||||
|
push_to_branch: dev
|
||||||
|
new_version: ${{ needs.get-update-version.outputs.new_version }}
|
||||||
|
|
||||||
noti-discord-manual-and-update-url-readme:
|
noti-discord-manual-and-update-url-readme:
|
||||||
needs: [build-macos, build-windows-x64, build-linux-x64, get-update-version, set-public-provider]
|
needs: [build-macos, build-windows-x64, build-linux-x64, get-update-version, set-public-provider]
|
||||||
secrets: inherit
|
secrets: inherit
|
||||||
|
|||||||
@ -1,50 +0,0 @@
|
|||||||
name: Jan Build Electron Pre Release
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
|
|
||||||
# Job create Update app version based on latest release tag with build number and save to output
|
|
||||||
get-update-version:
|
|
||||||
uses: ./.github/workflows/template-get-update-version.yml
|
|
||||||
|
|
||||||
build-macos:
|
|
||||||
uses: ./.github/workflows/template-build-macos.yml
|
|
||||||
secrets: inherit
|
|
||||||
needs: [get-update-version]
|
|
||||||
with:
|
|
||||||
ref: ${{ github.ref }}
|
|
||||||
public_provider: cloudflare-r2
|
|
||||||
new_version: ${{ needs.get-update-version.outputs.new_version }}
|
|
||||||
|
|
||||||
build-windows-x64:
|
|
||||||
uses: ./.github/workflows/template-build-windows-x64.yml
|
|
||||||
secrets: inherit
|
|
||||||
needs: [get-update-version]
|
|
||||||
with:
|
|
||||||
ref: ${{ github.ref }}
|
|
||||||
public_provider: cloudflare-r2
|
|
||||||
new_version: ${{ needs.get-update-version.outputs.new_version }}
|
|
||||||
|
|
||||||
build-linux-x64:
|
|
||||||
uses: ./.github/workflows/template-build-linux-x64.yml
|
|
||||||
secrets: inherit
|
|
||||||
needs: [get-update-version]
|
|
||||||
with:
|
|
||||||
ref: ${{ github.ref }}
|
|
||||||
public_provider: cloudflare-r2
|
|
||||||
new_version: ${{ needs.get-update-version.outputs.new_version }}
|
|
||||||
|
|
||||||
noti-discord-nightly-and-update-url-readme:
|
|
||||||
needs: [build-macos, build-windows-x64, build-linux-x64, get-update-version]
|
|
||||||
secrets: inherit
|
|
||||||
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
|
|
||||||
uses: ./.github/workflows/template-noti-discord-and-update-url-readme.yml
|
|
||||||
with:
|
|
||||||
ref: refs/heads/dev
|
|
||||||
build_reason: Nightly
|
|
||||||
push_to_branch: dev
|
|
||||||
new_version: ${{ needs.get-update-version.outputs.new_version }}
|
|
||||||
Loading…
x
Reference in New Issue
Block a user