-
Notifications
You must be signed in to change notification settings - Fork 11
103 lines (83 loc) · 2.6 KB
/
package-and-upload-new-mac.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
name: "Create GitHub Release for Mac"
on:
workflow_dispatch:
inputs:
git_tag:
description: "Git Branch Tag"
required: true
type: string
default: "main"
version:
description: "Release Version Tag"
required: true
type: string
default: "beta"
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.git_tag }}
- uses: pnpm/action-setup@v2
with:
version: 9
run_install: false
- uses: actions/setup-node@v4
with:
node-version: "20"
cache: "pnpm"
cache-dependency-path: "web/pnpm-lock.yaml"
- working-directory: "./web"
run: pnpm install
- working-directory: "./web"
run: pnpm turbo run build --filter=web
env:
NEXT_PUBLIC_API_URL: ${{ secrets.NEXT_PUBLIC_API_URL }}
- uses: actions/upload-artifact@v3
with:
name: web-build
path: web/apps/web/dist
package_shellagent_mac:
permissions:
contents: "write"
packages: "write"
pull-requests: "read"
needs: build
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.git_tag }}
fetch-depth: 0
persist-credentials: false
submodules: recursive
- uses: actions/setup-python@v5
with:
python-version: 3.10.10
- name: Download web-build artifact
uses: actions/download-artifact@v3
with:
name: web-build
path: ./servers/web-build
- shell: bash
run: |
cd ..
cp -r ShellAgent ShellAgent_copy
mkdir ShellAgent_MacOS_release
mv ShellAgent_copy ShellAgent_MacOS_release/ShellAgent
cd ShellAgent_MacOS_release
# curl -o Miniconda3-latest-MacOSX-arm64.sh https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-arm64.sh
# curl -o Miniconda3-latest-MacOSX-x86_64.sh https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-x86_64.sh
cp -r ShellAgent/.ci/MacOS_base_files/* ./
cd ..
zip -r ShellAgent_MacOS_release.zip ShellAgent_MacOS_release/
mv ShellAgent_MacOS_release.zip ShellAgent/ShellAgent_MacOS_release.zip
ls
- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: ShellAgent_MacOS_release.zip
tag: ${{ inputs.version }}
overwrite: true