* WIP: migrate from yarn v1 to npm * Add tsc mapping script * More fixes * Add playwright as script * Fix more * more and more people just want more * Merge branch 'main' into pierremtb/adhoc/npm * use workspaces and fix circular deps Signed-off-by: Jess Frazelle <github@jessfraz.com> * fmt Signed-off-by: Jess Frazelle <github@jessfraz.com> * fix Signed-off-by: Jess Frazelle <github@jessfraz.com> * New machine-api types * better lock file Signed-off-by: Jess Frazelle <github@jessfraz.com> * ignore typos in machine-api generated files Signed-off-by: Jess Frazelle <github@jessfraz.com> * updates Signed-off-by: Jess Frazelle <github@jessfraz.com> * install from root Signed-off-by: Jess Frazelle <github@jessfraz.com> * fix tsc Signed-off-by: Jess Frazelle <github@jessfraz.com> * New machine-api types * bettter install Signed-off-by: Jess Frazelle <github@jessfraz.com> * bettter install Signed-off-by: Jess Frazelle <github@jessfraz.com> * bettter install Signed-off-by: Jess Frazelle <github@jessfraz.com> * bettter install Signed-off-by: Jess Frazelle <github@jessfraz.com> * bettter install Signed-off-by: Jess Frazelle <github@jessfraz.com> * add comment Signed-off-by: Jess Frazelle <github@jessfraz.com> * add comment Signed-off-by: Jess Frazelle <github@jessfraz.com> --------- Signed-off-by: Jess Frazelle <github@jessfraz.com> Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com> Co-authored-by: Jess Frazelle <github@jessfraz.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
161 lines
4.6 KiB
YAML
161 lines
4.6 KiB
YAML
name: publish-apps-release
|
|
|
|
on:
|
|
release:
|
|
types: [published]
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
publish-apps-release:
|
|
runs-on: ubuntu-22.04
|
|
permissions:
|
|
contents: write
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version-file: '.nvmrc'
|
|
cache: 'npm'
|
|
|
|
- name: Find tag workflow id
|
|
id: tag_workflow_id
|
|
env:
|
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
run: |
|
|
id=$(gh run ls --repo kittycad/modeling-app -w build-apps.yml --branch ${{ github.event.release.tag_name }} --json databaseId | jq '.[0].databaseId')
|
|
echo "id=$id" >> "$GITHUB_OUTPUT"
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-arm64-win
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-x64-win
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-yml-win
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-arm64-mac
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-x64-mac
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-yml-mac
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-arm64-linux
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-x64-linux
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-yml-linux
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: out-download-json
|
|
path: out
|
|
run-id: ${{ steps.tag_workflow_id.outputs.id }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- name: List artifacts
|
|
run: ls -R out
|
|
|
|
- name: Override release notes
|
|
env:
|
|
NOTES: ${{ github.event.release.body }}
|
|
run: npm run files:set-notes
|
|
|
|
- name: Authenticate to Google Cloud
|
|
uses: 'google-github-actions/auth@v2.1.8'
|
|
with:
|
|
credentials_json: '${{ secrets.GOOGLE_CLOUD_DL_SA }}'
|
|
|
|
- name: Set up Google Cloud SDK
|
|
uses: google-github-actions/setup-gcloud@v2.1.4
|
|
with:
|
|
project_id: ${{ env.GOOGLE_CLOUD_PROJECT_ID }}
|
|
|
|
- name: Upload release files to public bucket
|
|
uses: google-github-actions/upload-cloud-storage@v2.2.2
|
|
with:
|
|
path: out
|
|
glob: '*'
|
|
parent: false
|
|
destination: 'dl.kittycad.io/releases/modeling-app'
|
|
|
|
- name: Invalidate bucket cache on latest*.yml and last_download.json files
|
|
run: npm run files:invalidate-bucket
|
|
|
|
- name: Upload release files to Github
|
|
if: ${{ github.event_name == 'release' }}
|
|
uses: softprops/action-gh-release@v2
|
|
with:
|
|
files: 'out/Zoo*'
|
|
|
|
|
|
announce_release:
|
|
needs: [publish-apps-release]
|
|
runs-on: ubuntu-22.04
|
|
steps:
|
|
- name: Check out code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: '3.x'
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
python -m pip install --upgrade pip
|
|
pip install requests
|
|
|
|
- name: Announce Release
|
|
env:
|
|
DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }}
|
|
RELEASE_VERSION: ${{ github.event.release.tag_name }}
|
|
RELEASE_BODY: ${{ github.event.release.body }}
|
|
run: python public/announce_release.py
|