Skip to content

Commit

Permalink
Updated CI so it uses new removed prerelease version
Browse files Browse the repository at this point in the history
  • Loading branch information
fayeed committed Oct 23, 2023
1 parent 51630b7 commit 6b132fb
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 17 deletions.
27 changes: 16 additions & 11 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,16 @@ jobs:
with:
path: ui

- name: Change package UI version
id: changed_version
run: cd ui && yarn change-ui-version

- name: Extract changed version
id: changed_extract_version
uses: Saionaro/extract-package-version@v1.1.1
with:
path: ui

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
Expand Down Expand Up @@ -232,11 +242,6 @@ jobs:
asset_name: ad4m-macos-${{ steps.extract_version.outputs.version }}-x64
asset_content_type: application/octet-stream

- name: Set Version Without Prerelease
id: set_version
if: matrix.platform == 'windows-latest'
run: echo "::set-output name=version::$(echo ${{ steps.extract_version.outputs.version }} -replace '-prerelease')"

- name: Upload Release MSI Asset
id: upload-release-msi-asset
if: matrix.platform == 'windows-latest'
Expand All @@ -245,8 +250,8 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create-release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM\ Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi
asset_name: ADAM\ Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi
asset_path: D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM\ Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi
asset_name: ADAM\ Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi
asset_content_type: application/octet-stream

- name: Upload Release MSI update Asset
Expand All @@ -257,8 +262,8 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create-release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM\ Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi.zip
asset_name: ADAM\ Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi.zip
asset_path: D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM\ Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi.zip
asset_name: ADAM\ Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi.zip
asset_content_type: application/octet-stream

- name: Upload Release MSI update sig Asset
Expand All @@ -269,8 +274,8 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create-release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM\ Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi.zip.sig
asset_name: ADAM\ Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi.zip.sig
asset_path: D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM\ Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi.zip.sig
asset_name: ADAM\ Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi.zip.sig
asset_content_type: application/octet-stream

# - name: Upload Release AD4M CLI Windows Binary
Expand Down
22 changes: 16 additions & 6 deletions .github/workflows/publish_staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,16 @@ jobs:
with:
path: ui

- name: Change package UI version
id: changed_version
run: cd ui && yarn change-ui-version

- name: Extract changed version
id: changed_extract_version
uses: Saionaro/extract-package-version@v1.1.1
with:
path: ui

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
Expand Down Expand Up @@ -243,8 +253,8 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create-release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: 'D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi'
asset_name: ADAM\ Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi
asset_path: 'D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi'
asset_name: ADAM\ Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi
asset_content_type: application/octet-stream

- name: Upload Release MSI update Asset
Expand All @@ -255,8 +265,8 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create-release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: 'D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi.zip'
asset_name: ADAM\ Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi.zip
asset_path: 'D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi.zip'
asset_name: ADAM\ Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi.zip
asset_content_type: application/octet-stream

- name: Upload Release MSI update sig Asset
Expand All @@ -267,8 +277,8 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ needs.create-release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: 'D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi.zip.sig'
asset_name: ADAM\ Launcher_${{ steps.set_version.outputs.version }}_x64_en-US.msi.zip.sig
asset_path: 'D:\a\ad4m\ad4m\target\release\bundle\msi\ADAM Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi.zip.sig'
asset_name: ADAM\ Launcher_${{ steps.changed_extract_version.outputs.version }}_x64_en-US.msi.zip.sig
asset_content_type: application/octet-stream

# - name: Upload Release AD4M CLI Windows Binary
Expand Down
1 change: 1 addition & 0 deletions ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
"tauri": "tauri",
"eject": "vite eject",
"build": "vite build",
"change-ui-version": "powershell -ExecutionPolicy Bypass -File ./scripts/patch-prerelease-tags.ps1",
"package-ad4m": "run-script-os",
"package-ad4m:windows": "cargo clean && powershell -ExecutionPolicy Bypass -File ./scripts/patch-prerelease-tags.ps1 && yarn run build && yarn tauri build --verbose && powershell -ExecutionPolicy Bypass -File ./scripts/reverse-patch-prerelease-tags.ps1",
"package-ad4m:macos": "yarn run build && yarn tauri build --verbose",
Expand Down

0 comments on commit 6b132fb

Please sign in to comment.