2024-06-09 22:56:42 +00:00
|
|
|
name: Build all artifacts and make release
|
|
|
|
|
|
|
|
on: workflow_dispatch
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
prepare:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
permissions:
|
|
|
|
contents: write
|
|
|
|
steps:
|
2024-06-09 23:01:25 +00:00
|
|
|
- name: Checkout repository
|
|
|
|
uses: actions/checkout@v4
|
2024-06-09 22:56:42 +00:00
|
|
|
- name: Get current block
|
|
|
|
id: getBlockHeight
|
|
|
|
run: echo "blockHeight=$(curl -s https://mempool.space/api/blocks/tip/height)" >> $GITHUB_OUTPUT
|
|
|
|
- name: Build Windows
|
2024-06-09 23:12:41 +00:00
|
|
|
uses: btclock/ota-flasher/.github/workflows/build_windows.yaml@main
|
2024-06-09 22:56:42 +00:00
|
|
|
- name: Build macOS
|
2024-06-09 23:12:41 +00:00
|
|
|
uses: btclock/ota-flasher/.github/workflows/build_macos.yaml@main
|
2024-06-09 22:56:42 +00:00
|
|
|
- name: Get Windows Artifacts
|
|
|
|
if: ${{ always() }}
|
|
|
|
uses: actions/download-artifact@v4
|
|
|
|
with:
|
|
|
|
name: windows-artifacts
|
|
|
|
path: windows
|
|
|
|
- name: Get Job 1 Artifacts
|
|
|
|
if: ${{ always() }}
|
|
|
|
uses: actions/download-artifact@v4
|
|
|
|
with:
|
|
|
|
name: macos-artifacts
|
|
|
|
path: macos
|
|
|
|
- name: Create release
|
|
|
|
uses: ncipollo/release-action@v1
|
|
|
|
with:
|
|
|
|
tag: ${{ steps.getBlockHeight.outputs.blockHeight }}
|
|
|
|
commit: main
|
|
|
|
name: release-${{ steps.getBlockHeight.outputs.blockHeight }}
|
|
|
|
artifacts: "macos/**/*.dmg,macos/**/*.zip,windows/**/*.exe"
|
|
|
|
allowUpdates: true
|
|
|
|
makeLatest: true
|