File tree 2 files changed +26
-6
lines changed
2 files changed +26
-6
lines changed Original file line number Diff line number Diff line change 30
30
repository_dispatch :
31
31
32
32
env :
33
+ PROJECT_NAME : arduino-create-agent
33
34
GO_VERSION : " 1.21"
34
35
35
36
jobs :
@@ -119,18 +120,38 @@ jobs:
119
120
run : task go:build-win # GOARCH=amd64 by default on the runners
120
121
if : runner.os == 'Windows' && matrix.arch == '-amd64'
121
122
122
- - name : Build the Agent for macos
123
+ - name : Build the Agent for macos amd 64
123
124
env :
124
125
MACOSX_DEPLOYMENT_TARGET : 10.15 # minimum supported version for mac
125
126
CGO_CFLAGS : -mmacosx-version-min=10.15
126
127
CGO_LDFLAGS : -mmacosx-version-min=10.15
127
- run : task go:build
128
+ run : |
129
+ task go:build
130
+ mv ${{ env.PROJECT_NAME }} ${{ env.PROJECT_NAME}}_amd64
131
+ if : runner.os == 'macOS'
132
+
133
+ - name : Build the Agent for macos amd 64
134
+ env :
135
+ MACOSX_DEPLOYMENT_TARGET : 10.15 # minimum supported version for mac
136
+ CGO_CFLAGS : -mmacosx-version-min=10.15
137
+ CGO_LDFLAGS : -mmacosx-version-min=10.15
138
+ GOARCH : arm64
139
+ CGO_ENABLED : 1
140
+ run : |
141
+ task go:build
142
+ mv ${{ env.PROJECT_NAME }} ${{ env.PROJECT_NAME}}_arm64
143
+ if : runner.os == 'macOS'
144
+
145
+ - name : Create universal macos executable
146
+ run : |
147
+ lipo -create -output ${{ env.PROJECT_NAME }} ${{ env.PROJECT_NAME}}_amd64 ${{ env.PROJECT_NAME}}_arm64
148
+ rm ${{ env.PROJECT_NAME}}_amd64 ${{ env.PROJECT_NAME}}_arm64
128
149
if : runner.os == 'macOS'
129
150
130
151
- name : Upload artifacts
131
152
uses : actions/upload-artifact@v4
132
153
with :
133
- name : arduino-create-agent -${{ matrix.os }}${{ matrix.arch }}
154
+ name : ${{ env.PROJECT_NAME}} -${{ matrix.os }}${{ matrix.arch }}
134
155
path : |
135
- arduino-create-agent *
156
+ ${{ env.PROJECT_NAME}} *
136
157
if-no-files-found : error
Original file line number Diff line number Diff line change 84
84
cmds :
85
85
- poetry run pytest tests
86
86
87
- # Source: https://github.com/arduino/tooling-project-assets/blob/main/workflow-templates/assets/poetry-task/Taskfile.yml
87
+ # Source: https://github.com/arduino/tooling-project-assets/blob/main/workflow-templates/assets/poetry-task/Taskfile.yml
88
88
poetry:install-deps :
89
89
desc : Install dependencies managed by Poetry
90
90
cmds :
@@ -138,7 +138,6 @@ tasks:
138
138
- task : go:vet
139
139
- task : go:lint
140
140
141
-
142
141
vars :
143
142
# Source: https://github.com/arduino/tooling-project-assets/blob/main/workflow-templates/assets/release-go-task/Taskfile.yml
144
143
PROJECT_NAME : arduino-create-agent
You can’t perform that action at this time.
0 commit comments