-
Notifications
You must be signed in to change notification settings - Fork 125
Expand file tree
/
Copy pathMakefile
More file actions
248 lines (192 loc) · 9.57 KB
/
Copy pathMakefile
File metadata and controls
248 lines (192 loc) · 9.57 KB
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
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
.PHONY: help doctor setup install-format-tools format-tools-status format format-check lint install-debug-cli uninstall-debug-cli debug-cli-status codex-acquire codex-status codex-update-candidate resolve build run test guardrails codex-schema-check conductor-selftest ci-app-test-runner-selftest release-selftest release-sync-cli-version release-preflight release-artifact install-local-production xcode xcode-open xcode-generate xcode-check xcode-validate xcode-clean dev-status dev-build dev-swift-build dev-run dev-launch-existing dev-codex-schema-check dev-test dev-provider-test dev-smoke dev-smoke-launch dev-format dev-format-check dev-lint dev-format-tools-status dev-check-format-tools dev-install-format-tools dev-release-preflight dev-release-artifact dev-install-local-production dev-stop-app dev-daemon-stop clean
PRODUCT ?= all
CODEX_ARCH ?= all
help:
@printf '%s\n' 'Usage: make <target>'
@printf '\n%s\n' 'Common targets:'
@printf ' %-30s %s\n' 'doctor' 'Verify local Swift/Xcode setup and diagnostics'
@printf ' %-30s %s\n' 'setup' 'Install format tools, run doctor, and resolve packages'
@printf ' %-30s %s\n' 'build' 'Build and package the debug app'
@printf ' %-30s %s\n' 'run' 'Build, package, and launch the debug app'
@printf ' %-30s %s\n' 'test' 'Run the Swift test suite'
@printf ' %-30s %s\n' 'guardrails' 'Run source layout and repository guardrails'
@printf ' %-30s %s\n' 'codex-schema-check' 'Validate bounded app-server assumptions against generated Codex schemas'
@printf ' %-30s %s\n' 'clean' 'Remove .build'
@printf '\n%s\n' 'Coordinated developer daemon targets:'
@printf ' %-30s %s\n' 'dev-status' 'Show conductor daemon status'
@printf ' %-30s %s\n' 'dev-build' 'Coordinated debug app package build'
@printf ' %-30s %s\n' 'dev-swift-build' 'Coordinated Swift build; override with PRODUCT=name'
@printf ' %-30s %s\n' 'dev-run' 'Coordinated debug app build and launch'
@printf ' %-30s %s\n' 'dev-launch-existing' 'Launch existing coordinated debug app without building'
@printf ' %-30s %s\n' 'dev-codex-schema-check' 'Coordinated Codex app-server schema validation'
@printf ' %-30s %s\n' 'dev-test' 'Coordinated test run; override with FILTER=name'
@printf ' %-30s %s\n' 'dev-provider-test' 'Run provider package tests; override with FILTER=name'
@printf ' %-30s %s\n' 'dev-smoke' 'Run non-disruptive live debug app smoke checks'
@printf ' %-30s %s\n' 'dev-smoke-launch' 'Launch debug app, then run smoke checks'
@printf ' %-30s %s\n' 'dev-stop-app' 'Stop the coordinated debug app'
@printf ' %-30s %s\n' 'dev-daemon-stop' 'Stop the conductor daemon'
@printf '\n%s\n' 'Style targets:'
@printf ' %-30s %s\n' 'format' 'Format Swift files directly'
@printf ' %-30s %s\n' 'format-check' 'Check Swift formatting directly'
@printf ' %-30s %s\n' 'lint' 'Run direct format-check and SwiftLint'
@printf ' %-30s %s\n' 'dev-format' 'Coordinated Swift formatting'
@printf ' %-30s %s\n' 'dev-format-check' 'Coordinated Swift formatting check'
@printf ' %-30s %s\n' 'dev-lint' 'Coordinated format-check and SwiftLint'
@printf ' %-30s %s\n' 'install-format-tools' 'Install SwiftFormat and SwiftLint'
@printf ' %-30s %s\n' 'format-tools-status' 'Show direct format tool status'
@printf ' %-30s %s\n' 'dev-install-format-tools' 'Coordinated format tool install'
@printf ' %-30s %s\n' 'dev-format-tools-status' 'Show coordinated format tool status'
@printf ' %-30s %s\n' 'dev-check-format-tools' 'Check coordinated format tool availability'
@printf '\n%s\n' 'Debug CLI targets:'
@printf ' %-30s %s\n' 'install-debug-cli' 'Build and install the CE debug CLI'
@printf ' %-30s %s\n' 'uninstall-debug-cli' 'Uninstall the CE debug CLI'
@printf ' %-30s %s\n' 'debug-cli-status' 'Show CE debug CLI status'
@printf ' %-30s %s\n' 'codex-acquire' 'Acquire and verify pinned Codex package(s); override with CODEX_ARCH=host|arm64|x86_64'
@printf ' %-30s %s\n' 'codex-status' 'Verify cached pinned Codex packages without network access'
@printf ' %-30s %s\n' 'codex-update-candidate' 'Prepare review-only stable Codex update evidence; set one CODEX_CANDIDATE selector'
@printf '\n%s\n' 'Xcode workspace targets:'
@printf ' %-30s %s\n' 'xcode' 'Generate and open the disposable Xcode workspace'
@printf ' %-30s %s\n' 'xcode-generate' 'Generate the disposable Xcode workspace'
@printf ' %-30s %s\n' 'xcode-check' 'Check generated Xcode workspace state'
@printf ' %-30s %s\n' 'xcode-validate' 'Full Xcode workspace validation, including xcodebuild -list'
@printf ' %-30s %s\n' 'xcode-clean' 'Remove generated Xcode workspace metadata'
@printf '\n%s\n' 'Release targets:'
@printf ' %-30s %s\n' 'release-preflight' 'Run release preflight directly'
@printf ' %-30s %s\n' 'release-artifact' 'Build release artifact directly'
@printf ' %-30s %s\n' 'install-local-production' 'Install a local production app'
@printf ' %-30s %s\n' 'dev-release-preflight' 'Coordinated release preflight'
@printf ' %-30s %s\n' 'dev-release-artifact' 'Coordinated release artifact build'
@printf ' %-30s %s\n' 'dev-install-local-production' 'Coordinated local production install'
@printf '\n%s\n' 'Internal/test targets:'
@printf ' %-30s %s\n' 'resolve' 'Resolve Swift packages'
@printf ' %-30s %s\n' 'conductor-selftest' 'Run conductor/tooling self-tests'
@printf ' %-30s %s\n' 'ci-app-test-runner-selftest' 'Run hosted CI app-test runner self-tests'
@printf ' %-30s %s\n' 'release-selftest' 'Run release tooling self-tests'
@printf ' %-30s %s\n' 'release-sync-cli-version' 'Sync CLI version for release tooling'
doctor:
./Scripts/doctor.sh
setup:
./Scripts/install_format_tools.sh install
./Scripts/doctor.sh
swift package resolve
install-format-tools:
./Scripts/install_format_tools.sh install
format-tools-status:
./Scripts/install_format_tools.sh status
format:
./Scripts/swift_style.sh format
format-check:
./Scripts/swift_style.sh format-check
lint:
./Scripts/swift_style.sh lint
install-debug-cli:
./Scripts/install_debug_cli.sh install --build
uninstall-debug-cli:
./Scripts/install_debug_cli.sh uninstall
debug-cli-status:
./Scripts/install_debug_cli.sh status
codex-acquire:
python3 Scripts/codex_runtime_artifact.py acquire --arch $(CODEX_ARCH) --cache-root "$${REPOPROMPT_CODEX_CACHE_ROOT:-.build/codex-runtime}"
codex-status:
python3 Scripts/codex_runtime_artifact.py status --cache-root "$${REPOPROMPT_CODEX_CACHE_ROOT:-.build/codex-runtime}"
codex-update-candidate:
@set --; count=0; \
if [ -n "$(CODEX_CANDIDATE_VERSION)" ]; then count=$$((count + 1)); set -- "$$@" --version "$(CODEX_CANDIDATE_VERSION)"; fi; \
if [ -n "$(CODEX_CANDIDATE_TAG)" ]; then count=$$((count + 1)); set -- "$$@" --tag "$(CODEX_CANDIDATE_TAG)"; fi; \
if [ "$(CODEX_CANDIDATE_LATEST)" = "1" ]; then count=$$((count + 1)); set -- "$$@" --latest-stable; fi; \
if [ "$$count" -ne 1 ]; then \
echo "Set exactly one of CODEX_CANDIDATE_VERSION=X.Y.Z, CODEX_CANDIDATE_TAG=rust-vX.Y.Z, or CODEX_CANDIDATE_LATEST=1" >&2; \
exit 1; \
fi; \
python3 Scripts/codex_update_candidate.py "$$@"
resolve:
swift package resolve
build:
./Scripts/package_app.sh debug
run:
./Scripts/run.sh
test:
swift test
guardrails:
./Scripts/guardrails.sh
codex-schema-check:
python3 Scripts/check_codex_app_server_schema.py
conductor-selftest:
python3 Scripts/test_codex_app_server_schema.py
python3 Scripts/test_debug_app_process.py
python3 Scripts/test_ci_app_test_runner.py
python3 Scripts/test_conductor_diagnostics.py
python3 Scripts/test_local_production_installer.py
python3 Scripts/test_security_inventory.py
ci-app-test-runner-selftest:
python3 Scripts/test_ci_app_test_runner.py
release-selftest:
python3 Scripts/test_release_tooling.py
python3 Scripts/test_publish_tip_release.py
python3 Scripts/test_codex_runtime_artifact.py
python3 Scripts/test_codex_update_candidate.py
python3 Scripts/test_codex_update_workflow.py
./Scripts/test_release_split_metadata_root.sh
release-sync-cli-version:
./Scripts/release.sh sync-cli-version
release-preflight:
./Scripts/release.sh preflight
release-artifact:
./Scripts/release.sh artifact
install-local-production:
./Scripts/install_local_production.sh
xcode: xcode-open
xcode-open: xcode-generate
open "$$(python3 Scripts/generate_xcode_workspace.py print-path)"
xcode-generate:
python3 Scripts/generate_xcode_workspace.py generate
xcode-check:
python3 Scripts/generate_xcode_workspace.py check
xcode-validate: xcode-generate
python3 Scripts/generate_xcode_workspace.py validate --xcodebuild-list
xcode-clean:
rm -rf .build/xcode .build/xcode-custom
dev-status:
./conductor status
dev-build:
./conductor build
dev-swift-build:
./conductor swift-build --product $(PRODUCT)
dev-run:
./conductor run
dev-launch-existing:
./conductor app launch-existing
dev-codex-schema-check:
./conductor codex-schema-check
dev-test:
./conductor test$(if $(TEST_PRODUCT), --test-product $(TEST_PRODUCT))$(if $(FILTER), --filter $(FILTER))
dev-provider-test:
./conductor provider-test$(if $(TEST_PRODUCT), --test-product $(TEST_PRODUCT))$(if $(FILTER), --filter $(FILTER))
dev-smoke:
./conductor smoke
dev-smoke-launch:
./conductor smoke --launch
dev-format:
./conductor format
dev-format-check:
./conductor format-check
dev-lint:
./conductor lint
dev-format-tools-status:
./conductor format-tools-status
dev-check-format-tools:
./conductor check-format-tools
dev-install-format-tools:
./conductor install-format-tools
dev-release-preflight:
./conductor release preflight
dev-release-artifact:
./conductor release artifact
dev-install-local-production:
./conductor release local-install
dev-stop-app:
./conductor app stop
dev-daemon-stop:
./conductor daemon stop
clean:
rm -rf .build