Compare commits

...

13 Commits

3 changed files with 67 additions and 56 deletions

View File

@ -5,12 +5,14 @@ on:
push: push:
branches: branches:
- main - main
- updater-test
tags: tags:
- 'v[0-9]+.[0-9]+.[0-9]+' - 'v[0-9]+.[0-9]+.[0-9]+'
- 'nightly-v[0-9]+.[0-9]+.[0-9]+' - 'nightly-v[0-9]+.[0-9]+.[0-9]+'
env: env:
IS_RELEASE: ${{ github.ref_type == 'tag' && startsWith(github.ref_name, 'v') }} # IS_RELEASE: ${{ github.ref_type == 'tag' && startsWith(github.ref_name, 'v') }}
IS_RELEASE: true
IS_NIGHTLY: ${{ github.ref_type == 'tag' && startsWith(github.ref_name, 'nightly-v') }} IS_NIGHTLY: ${{ github.ref_type == 'tag' && startsWith(github.ref_name, 'nightly-v') }}
concurrency: concurrency:
@ -99,11 +101,11 @@ jobs:
npm run files:set-version npm run files:set-version
npm run files:flip-to-nightly npm run files:flip-to-nightly
- name: Set release version # - name: Set release version
if: ${{ env.IS_RELEASE == 'true' }} # if: ${{ env.IS_RELEASE == 'true' }}
run: | # run: |
export VERSION=${GITHUB_REF_NAME#v} # export VERSION=${GITHUB_REF_NAME#v}
npm run files:set-version # npm run files:set-version
- uses: actions/upload-artifact@v4 - uses: actions/upload-artifact@v4
with: with:
@ -122,17 +124,17 @@ jobs:
- id: export_notes - id: export_notes
run: echo "notes=`cat release-notes.md`" >> "$GITHUB_OUTPUT" run: echo "notes=`cat release-notes.md`" >> "$GITHUB_OUTPUT"
- name: Prepare electron-builder.yml file for updater test # - name: Prepare electron-builder.yml file for updater test
if: ${{ env.IS_RELEASE == 'true' }} # if: ${{ env.IS_RELEASE == 'true' }}
run: | # run: |
yq -i '.publish[0].url = "https://dl.zoo.dev/releases/modeling-app/updater-test"' electron-builder.yml # yq -i '.publish[0].url = "https://dl.zoo.dev/releases/modeling-app/updater-test"' electron-builder.yml
- uses: actions/upload-artifact@v4 # - uses: actions/upload-artifact@v4
if: ${{ env.IS_RELEASE == 'true' }} # if: ${{ env.IS_RELEASE == 'true' }}
with: # with:
name: prepared-files-updater-test # name: prepared-files-updater-test
path: | # path: |
electron-builder.yml # electron-builder.yml
build-apps: build-apps:
@ -260,53 +262,53 @@ jobs:
# The steps below are for updater-test builds, only on release # The steps below are for updater-test builds, only on release
- uses: actions/download-artifact@v4 # - uses: actions/download-artifact@v4
if: ${{ env.IS_RELEASE == 'true' }} # if: ${{ env.IS_RELEASE == 'true' }}
name: prepared-files-updater-test # name: prepared-files-updater-test
- name: Copy updated electron-builder.yml file for updater test # - name: Copy updated electron-builder.yml file for updater test
if: ${{ env.IS_RELEASE == 'true' }} # if: ${{ env.IS_RELEASE == 'true' }}
run: | # run: |
ls -R prepared-files-updater-test # ls -R prepared-files-updater-test
cp prepared-files-updater-test/electron-builder.yml electron-builder.yml # cp prepared-files-updater-test/electron-builder.yml electron-builder.yml
- name: Build the app (updater-test) # - name: Build the app (updater-test)
if: ${{ env.IS_RELEASE == 'true' }} # if: ${{ env.IS_RELEASE == 'true' }}
env: # env:
APPLE_ID: ${{ secrets.APPLE_ID }} # APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_PASSWORD: ${{ secrets.APPLE_PASSWORD }} # APPLE_PASSWORD: ${{ secrets.APPLE_PASSWORD }}
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.APPLE_PASSWORD }} # APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.APPLE_PASSWORD }}
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }} # APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
CSC_LINK: ${{ secrets.APPLE_CERTIFICATE }} # CSC_LINK: ${{ secrets.APPLE_CERTIFICATE }}
CSC_KEY_PASSWORD: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }} # CSC_KEY_PASSWORD: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
CSC_KEYCHAIN: ${{ secrets.APPLE_SIGNING_IDENTITY }} # CSC_KEYCHAIN: ${{ secrets.APPLE_SIGNING_IDENTITY }}
WINDOWS_CERTIFICATE_THUMBPRINT: ${{ secrets.WINDOWS_CERTIFICATE_THUMBPRINT }} # WINDOWS_CERTIFICATE_THUMBPRINT: ${{ secrets.WINDOWS_CERTIFICATE_THUMBPRINT }}
run: npm run tronb:package:prod # run: npm run tronb:package:prod
- uses: actions/upload-artifact@v4 # - uses: actions/upload-artifact@v4
if: ${{ env.IS_RELEASE == 'true' }} # if: ${{ env.IS_RELEASE == 'true' }}
with: # with:
name: updater-test-arm64-${{ matrix.platform }} # name: updater-test-arm64-${{ matrix.platform }}
path: | # path: |
out/*-arm64-win.exe # out/*-arm64-win.exe
out/*-arm64-mac.dmg # out/*-arm64-mac.dmg
out/*-arm64-linux.AppImage # out/*-arm64-linux.AppImage
- uses: actions/upload-artifact@v4 # - uses: actions/upload-artifact@v4
if: ${{ env.IS_RELEASE == 'true' }} # if: ${{ env.IS_RELEASE == 'true' }}
with: # with:
name: updater-test-x64-${{ matrix.platform }} # name: updater-test-x64-${{ matrix.platform }}
path: | # path: |
out/*-x64-win.exe # out/*-x64-win.exe
out/*-x64-mac.dmg # out/*-x64-mac.dmg
out/*-x86_64-linux.AppImage # out/*-x86_64-linux.AppImage
upload-apps-release: upload-apps-release:
runs-on: ubuntu-22.04 runs-on: ubuntu-22.04
permissions: permissions:
contents: write contents: write
if: ${{ github.ref_type == 'tag' }} # if: ${{ github.ref_type == 'tag' }}
env: env:
VERSION_NO_V: ${{ needs.prepare-files.outputs.version }} VERSION_NO_V: ${{ needs.prepare-files.outputs.version }}
VERSION: ${{ format('v{0}', needs.prepare-files.outputs.version) }} VERSION: ${{ format('v{0}', needs.prepare-files.outputs.version) }}
@ -424,13 +426,13 @@ jobs:
npm run files:set-notes npm run files:set-notes
- name: Authenticate to Google Cloud - name: Authenticate to Google Cloud
if: ${{ env.IS_NIGHTLY == 'true' }} # if: ${{ env.IS_NIGHTLY == 'true' }}
uses: 'google-github-actions/auth@v2.1.8' uses: 'google-github-actions/auth@v2.1.8'
with: with:
credentials_json: '${{ secrets.GOOGLE_CLOUD_DL_SA }}' credentials_json: '${{ secrets.GOOGLE_CLOUD_DL_SA }}'
- name: Set up Google Cloud SDK - name: Set up Google Cloud SDK
if: ${{ env.IS_NIGHTLY == 'true' }} # if: ${{ env.IS_NIGHTLY == 'true' }}
uses: google-github-actions/setup-gcloud@v2.1.4 uses: google-github-actions/setup-gcloud@v2.1.4
with: with:
project_id: ${{ env.GOOGLE_CLOUD_PROJECT_ID }} project_id: ${{ env.GOOGLE_CLOUD_PROJECT_ID }}
@ -444,6 +446,14 @@ jobs:
parent: false parent: false
destination: 'dl.kittycad.io/releases/modeling-app/nightly' destination: 'dl.kittycad.io/releases/modeling-app/nightly'
- name: Upload updater-test files to public bucket
uses: google-github-actions/upload-cloud-storage@v2.2.1
with:
path: out
glob: '*'
parent: false
destination: 'dl.kittycad.io/releases/modeling-app/updater-test'
- name: Invalidate bucket cache on latest*.yml and last_download.json files - name: Invalidate bucket cache on latest*.yml and last_download.json files
if: ${{ env.IS_NIGHTLY == 'true' }} if: ${{ env.IS_NIGHTLY == 'true' }}
run: npm run files:invalidate-bucket:nightly run: npm run files:invalidate-bucket:nightly

View File

@ -1,6 +1,6 @@
{ {
"name": "zoo-modeling-app", "name": "zoo-modeling-app",
"version": "0.0.0", "version": "0.255.255",
"private": true, "private": true,
"productName": "Zoo Design Studio", "productName": "Zoo Design Studio",
"author": { "author": {

View File

@ -0,0 +1 @@
Updater-test dummy notes. [Test link](https://zoo.dev)