theslopmachine 0.6.2 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (76) hide show
  1. package/MANUAL.md +21 -6
  2. package/README.md +55 -7
  3. package/RELEASE.md +15 -0
  4. package/assets/agents/developer.md +41 -1
  5. package/assets/agents/slopmachine-claude.md +100 -60
  6. package/assets/agents/slopmachine.md +40 -17
  7. package/assets/claude/agents/developer.md +42 -5
  8. package/assets/skills/clarification-gate/SKILL.md +25 -5
  9. package/assets/skills/claude-worker-management/SKILL.md +280 -57
  10. package/assets/skills/developer-session-lifecycle/SKILL.md +81 -37
  11. package/assets/skills/development-guidance/SKILL.md +21 -1
  12. package/assets/skills/evaluation-triage/SKILL.md +32 -23
  13. package/assets/skills/final-evaluation-orchestration/SKILL.md +86 -50
  14. package/assets/skills/hardening-gate/SKILL.md +17 -3
  15. package/assets/skills/integrated-verification/SKILL.md +3 -3
  16. package/assets/skills/planning-gate/SKILL.md +32 -3
  17. package/assets/skills/planning-guidance/SKILL.md +72 -13
  18. package/assets/skills/retrospective-analysis/SKILL.md +2 -2
  19. package/assets/skills/scaffold-guidance/SKILL.md +129 -124
  20. package/assets/skills/submission-packaging/SKILL.md +33 -27
  21. package/assets/skills/verification-gates/SKILL.md +44 -14
  22. package/assets/slopmachine/backend-evaluation-prompt.md +1 -1
  23. package/assets/slopmachine/frontend-evaluation-prompt.md +5 -5
  24. package/assets/slopmachine/scaffold-playbooks/android-kotlin-compose.md +81 -0
  25. package/assets/slopmachine/scaffold-playbooks/android-kotlin-views.md +191 -0
  26. package/assets/slopmachine/scaffold-playbooks/android-native-java.md +203 -0
  27. package/assets/slopmachine/scaffold-playbooks/angular-default.md +181 -0
  28. package/assets/slopmachine/scaffold-playbooks/backend-baseline.md +142 -0
  29. package/assets/slopmachine/scaffold-playbooks/backend-family-matrix.md +80 -0
  30. package/assets/slopmachine/scaffold-playbooks/database-module-matrix.md +80 -0
  31. package/assets/slopmachine/scaffold-playbooks/django-default.md +166 -0
  32. package/assets/slopmachine/scaffold-playbooks/docker-baseline.md +189 -0
  33. package/assets/slopmachine/scaffold-playbooks/docker-shared-contract.md +334 -0
  34. package/assets/slopmachine/scaffold-playbooks/electron-vite-default.md +124 -0
  35. package/assets/slopmachine/scaffold-playbooks/expo-react-native-default.md +73 -0
  36. package/assets/slopmachine/scaffold-playbooks/fastapi-default.md +134 -0
  37. package/assets/slopmachine/scaffold-playbooks/frontend-baseline.md +160 -0
  38. package/assets/slopmachine/scaffold-playbooks/frontend-family-matrix.md +134 -0
  39. package/assets/slopmachine/scaffold-playbooks/generic-unknown-tech-guide.md +136 -0
  40. package/assets/slopmachine/scaffold-playbooks/go-chi-default.md +160 -0
  41. package/assets/slopmachine/scaffold-playbooks/ios-linux-portable.md +93 -0
  42. package/assets/slopmachine/scaffold-playbooks/ios-native-objective-c.md +151 -0
  43. package/assets/slopmachine/scaffold-playbooks/ios-native-swift.md +188 -0
  44. package/assets/slopmachine/scaffold-playbooks/laravel-default.md +216 -0
  45. package/assets/slopmachine/scaffold-playbooks/livewire-default.md +265 -0
  46. package/assets/slopmachine/scaffold-playbooks/overlay-module-matrix.md +130 -0
  47. package/assets/slopmachine/scaffold-playbooks/platform-family-matrix.md +79 -0
  48. package/assets/slopmachine/scaffold-playbooks/selection-matrix.md +72 -0
  49. package/assets/slopmachine/scaffold-playbooks/spring-boot-default.md +182 -0
  50. package/assets/slopmachine/scaffold-playbooks/tauri-default.md +80 -0
  51. package/assets/slopmachine/scaffold-playbooks/vue-vite-default.md +162 -0
  52. package/assets/slopmachine/scaffold-playbooks/web-default.md +96 -0
  53. package/assets/slopmachine/templates/AGENTS.md +41 -3
  54. package/assets/slopmachine/templates/CLAUDE.md +111 -0
  55. package/assets/slopmachine/utils/claude_create_session.mjs +1 -0
  56. package/assets/slopmachine/utils/claude_live_channel.mjs +188 -0
  57. package/assets/slopmachine/utils/claude_live_common.mjs +406 -0
  58. package/assets/slopmachine/utils/claude_live_hook.py +47 -0
  59. package/assets/slopmachine/utils/claude_live_launch.mjs +181 -0
  60. package/assets/slopmachine/utils/claude_live_status.mjs +25 -0
  61. package/assets/slopmachine/utils/claude_live_stop.mjs +45 -0
  62. package/assets/slopmachine/utils/claude_live_turn.mjs +250 -0
  63. package/assets/slopmachine/utils/claude_resume_session.mjs +1 -0
  64. package/assets/slopmachine/utils/claude_wait_for_rate_limit_reset.mjs +23 -0
  65. package/assets/slopmachine/utils/claude_wait_for_rate_limit_reset.sh +5 -0
  66. package/assets/slopmachine/utils/claude_worker_common.mjs +224 -4
  67. package/assets/slopmachine/utils/cleanup_delivery_artifacts.py +4 -0
  68. package/assets/slopmachine/utils/export_ai_session.mjs +1 -1
  69. package/assets/slopmachine/utils/normalize_claude_session.py +153 -0
  70. package/assets/slopmachine/utils/package_claude_session.mjs +96 -0
  71. package/assets/slopmachine/utils/prepare_strict_audit_workspace.mjs +65 -0
  72. package/package.json +1 -1
  73. package/src/constants.js +42 -3
  74. package/src/init.js +173 -28
  75. package/src/install.js +75 -0
  76. package/src/send-data.js +56 -57
@@ -0,0 +1,160 @@
1
+ # Go Chi Default Scaffold Playbook
2
+
3
+ Use this playbook when the request explicitly asks for a Go baseline or when the backend family has already been narrowed to Go and there is no repo evidence pushing Gin or a heavier framework.
4
+
5
+ Verified lab: `/Users/yohannesakd/code/eaglepoint/demonstration/scaffold-lab/go-chi-baseline`
6
+
7
+ ## Goal
8
+
9
+ Create a Go-only baseline that:
10
+
11
+ - follows the default Go family direction in `backend-family-matrix.md`
12
+ - keeps dependency versions pinned and conservative
13
+ - uses a safe default database pattern with real persistence
14
+ - makes `docker compose up --build` the primary runtime command
15
+ - makes `./run_tests.sh` the portable broad verification command
16
+ - includes minimal real API tests
17
+ - stops at baseline infrastructure instead of product features
18
+
19
+ ## Why Chi remains the default
20
+
21
+ - `backend-family-matrix.md` already marks Go + Chi as the safe default when the prompt only says Go.
22
+ - The Go project guidance for server projects recommends `cmd/` plus `internal/` packages, which fits a small Chi service cleanly.
23
+ - Chi's documented `chi.NewRouter()` plus middleware stack provides a real HTTP surface without adding heavier framework defaults that the baseline does not need.
24
+
25
+ Gin stays a fallback only when the prompt explicitly wants Gin or clearly benefits from higher-level binding helpers.
26
+
27
+ ## Bootstrap rule
28
+
29
+ - use the standard Go module bootstrap plus Chi
30
+ - keep the module layout small and explicit
31
+ - do not add code generators or larger framework layers just to make the tree feel more enterprise-shaped
32
+
33
+ Reusable bootstrap commands:
34
+
35
+ ```bash
36
+ go mod init go-chi-baseline
37
+ go get github.com/go-chi/chi/v5@v5.2.5
38
+ go get modernc.org/sqlite@v1.37.1
39
+ go test ./...
40
+ go run ./cmd/server
41
+ ```
42
+
43
+ ## Safe pinned defaults
44
+
45
+ - Go `1.24.2`
46
+ - Chi `v5.2.5`
47
+ - SQLite driver `modernc.org/sqlite v1.37.1`
48
+ - Docker builder image: `golang:1.24.2-alpine3.21`
49
+ - Docker runtime image: `alpine:3.21`
50
+
51
+ ## Database pattern
52
+
53
+ - default to SQLite for the baseline because it keeps the local runtime secret-free and easy to verify
54
+ - place the SQLite file in a Docker-managed volume, not in the repo
55
+ - generate the runtime config file at container startup instead of committing `.env`
56
+ - keep `./init_db.sh` as the single database bootstrap entrypoint
57
+ - use `database/sql` with one explicit store package and idempotent schema bootstrap
58
+
59
+ ## Required runtime contract
60
+
61
+ - runtime: `docker compose up --build`
62
+ - tests: `./run_tests.sh`
63
+ - DB bootstrap: `./init_db.sh`
64
+ - all three commands must be real
65
+
66
+ ## Minimum API floor
67
+
68
+ At baseline, include all of the following:
69
+
70
+ - `GET /health` proving API boot and database connectivity
71
+ - `POST /items` creating a persisted record
72
+ - `GET /items` returning persisted records
73
+ - at least two real tests hitting those routes through `httptest`
74
+
75
+ ## Compose pattern
76
+
77
+ - one `app` service
78
+ - one `test` service behind a `test` profile using the same source tree in a containerized Go toolchain
79
+ - expose only the API port to `127.0.0.1`
80
+ - prefer Docker-assigned random host ports to avoid collisions
81
+ - include an app healthcheck that exercises `/health`
82
+ - store generated config and DB state in named volumes
83
+
84
+ ## README requirements
85
+
86
+ `README.md` must state:
87
+
88
+ - that this is baseline only
89
+ - the exact pinned stack
90
+ - the exact runtime command
91
+ - the exact test command
92
+ - the exact DB bootstrap command
93
+ - that no `.env` file is used
94
+ - what is intentionally excluded
95
+
96
+ ## Experimental verification for this lab
97
+
98
+ Commands run in `/Users/yohannesakd/code/eaglepoint/demonstration/scaffold-lab/go-chi-baseline`:
99
+
100
+ ```bash
101
+ docker compose build
102
+ ./init_db.sh
103
+ docker compose up --build -d
104
+ docker compose ps
105
+ docker compose port app 8080
106
+ curl -fsS "http://127.0.0.1:32806/health"
107
+ curl -fsS -X POST "http://127.0.0.1:32806/items" -H "content-type: application/json" -d '{"name":"manual-smoke-item"}'
108
+ curl -fsS "http://127.0.0.1:32806/items"
109
+ docker compose down --volumes --remove-orphans
110
+ python3 - <<'PY'
111
+ import signal
112
+ import subprocess
113
+ import time
114
+ from urllib.request import urlopen
115
+
116
+ cwd = "/Users/yohannesakd/code/eaglepoint/demonstration/scaffold-lab/go-chi-baseline"
117
+ proc = subprocess.Popen(["docker", "compose", "up", "--build"], cwd=cwd)
118
+ error = None
119
+ try:
120
+ deadline = time.time() + 180
121
+ while time.time() < deadline:
122
+ try:
123
+ port_output = subprocess.check_output(["docker", "compose", "port", "app", "8080"], cwd=cwd, text=True).strip()
124
+ if port_output:
125
+ host = port_output.split(":")[-1]
126
+ with urlopen(f"http://127.0.0.1:{host}/health", timeout=2) as response:
127
+ body = response.read().decode("utf-8")
128
+ if response.status == 200 and '"status":"ok"' in body and '"database":"ok"' in body:
129
+ print(f"docker compose up --build reached healthy /health on http://127.0.0.1:{host}/health")
130
+ break
131
+ except Exception as exc:
132
+ error = exc
133
+ time.sleep(2)
134
+ else:
135
+ raise RuntimeError(f"go chi baseline never became ready: {error}")
136
+ finally:
137
+ proc.send_signal(signal.SIGINT)
138
+ try:
139
+ proc.wait(timeout=30)
140
+ except subprocess.TimeoutExpired:
141
+ proc.kill()
142
+ proc.wait(timeout=30)
143
+ subprocess.run(["docker", "compose", "down", "-v", "--remove-orphans"], cwd=cwd, check=True)
144
+ PY
145
+ ./run_tests.sh
146
+ ```
147
+
148
+ Observed result:
149
+
150
+ - `./init_db.sh` printed `database initialized`
151
+ - detached startup reached healthy state on `127.0.0.1:32806`
152
+ - `GET /health`, `POST /items`, and `GET /items` all returned successful real API responses against the running container
153
+ - attached `docker compose up --build` reached a healthy `/health` endpoint at `http://127.0.0.1:32807/health` before controlled shutdown
154
+ - `./run_tests.sh` finished with passing Go tests and printed `Go Chi smoke check passed at http://app:8080`
155
+
156
+ ## Expected caveats
157
+
158
+ - the baseline uses idempotent schema bootstrap instead of a full migration framework
159
+ - SQLite is the safe local baseline default, not a production concurrency recommendation
160
+ - switch to PostgreSQL only when the prompt or existing repo actually needs a network database
@@ -0,0 +1,93 @@
1
+ # iOS On Linux Portable Scaffold Playbook
2
+
3
+ Use this playbook when the request is iOS-targeted but the workflow is executing on Linux or another non-Xcode host.
4
+
5
+ ## Goal
6
+
7
+ Create an honest baseline that:
8
+
9
+ - sets up the requested iOS-facing codebase or shared codebase correctly
10
+ - stays baseline-only, not feature-complete
11
+ - exposes one honest broad test command that works on Linux
12
+ - does not fake native iOS runtime or simulator proof
13
+
14
+ ## Runtime contract
15
+
16
+ - required Docker command: `docker compose up --build`
17
+ - required broad test command: `./run_tests.sh`
18
+ - both commands must be real and working
19
+ - if a real host-side helper exists, `./run_app.sh` may also exist, but it does not replace the required Docker baseline
20
+ - do not claim native iOS runtime proof from Linux
21
+
22
+ ## Baseline rule
23
+
24
+ - follow the requested stack first
25
+ - use safe defaults unless the prompt clearly asks for something else
26
+ - Expo-managed React Native is the default safe baseline when the goal is iOS-targeted work from Linux
27
+ - if the stack supports shared JS/TS or portable logic tests, wire those now
28
+ - if true native iOS runtime/build proof requires macOS/Xcode, state that clearly in `README.md` during scaffold
29
+ - never treat web preview, screenshots, or static bundle export as standalone native iOS proof
30
+
31
+ ## Safe default iOS-on-Linux baseline
32
+
33
+ Prefer an Expo-managed TypeScript baseline that honestly proves the parts Linux can cover:
34
+
35
+ - shared React Native UI/state code
36
+ - containerized Jest and typecheck coverage
37
+ - `expo export --platform ios` or equivalent JS/assets export as build-shape proof
38
+ - Expo dev-server startup for manual device-adjacent checks when appropriate
39
+
40
+ Do **not** claim these prove:
41
+
42
+ - Xcode build success
43
+ - CocoaPods/native module integration quality on macOS
44
+ - iOS simulator behavior
45
+ - code signing, archive, or App Store readiness
46
+
47
+ ## Minimal real test floor
48
+
49
+ At scaffold, include at least:
50
+
51
+ - one real portable test
52
+ - one real lint/typecheck/build-shape verification in `./run_tests.sh`
53
+ - one real Docker-backed runtime/build path behind `docker compose up --build`
54
+ - one honest statement of what cannot yet be proven on Linux
55
+ - no committed `.env`
56
+
57
+ Recommended Linux broad path for an Expo baseline:
58
+
59
+ - `tsc --noEmit`
60
+ - `jest --runInBand`
61
+ - `expo export --platform ios`
62
+
63
+ ## README floor
64
+
65
+ `README.md` must already state:
66
+
67
+ - scaffold status versus implemented scope
68
+ - required Docker command: `docker compose up --build`
69
+ - broad test command: `./run_tests.sh`
70
+ - host-side helper command when one honestly exists
71
+ - whether `./run_app.sh` is the closest manual device-adjacent flow
72
+ - native iOS runtime/build proof is out of scope on Linux unless a separate macOS/Xcode checkpoint exists
73
+ - whether the scaffold proves Expo/shared-code behavior only versus native standalone app behavior
74
+
75
+ ## Common pitfalls
76
+
77
+ - pretending Linux scaffold proves native iOS runtime quality
78
+ - hiding the macOS/Xcode dependency for native proof
79
+ - leaving `docker compose up --build` or `./run_tests.sh` empty because true native iOS runtime is unavailable
80
+ - relying on `.env` during scaffold when safe defaults work
81
+ - implying that Expo Go or a JS bundle export equals native binary proof
82
+
83
+ ## Acceptance checklist
84
+
85
+ Scaffold is acceptable when:
86
+
87
+ - the portable baseline is real
88
+ - `docker compose up --build` works honestly
89
+ - `./run_tests.sh` works honestly on Linux
90
+ - `./run_app.sh` exists when it materially improves the closest honest local flow
91
+ - no `.env` file is required for the baseline
92
+ - proof limitations are documented clearly
93
+ - README is honest about the boundary
@@ -0,0 +1,151 @@
1
+ # iOS Native Objective-C Scaffold Playbook
2
+
3
+ Use this playbook only when the prompt explicitly requires a native Objective-C iOS app or the existing repo is already Objective-C-first.
4
+
5
+ ## Goal
6
+
7
+ Create an honest baseline that:
8
+
9
+ - keeps Objective-C native iOS as the selected family
10
+ - uses the real Apple/Xcode bootstrap concept instead of an invented Linux-native starter
11
+ - preserves a real Linux verification contract without faking native iOS build or runtime proof
12
+ - proves the strongest Linux boundary with a committed Xcode-shaped project, shared scheme, and static verification report
13
+ - keeps the family explicit opt-in and non-default on Linux
14
+
15
+ ## Family status
16
+
17
+ - this is a **non-default** family
18
+ - do **not** auto-select it for open-ended iOS work on Linux
19
+ - when the prompt is iOS-targeted on Linux without a native Objective-C requirement, prefer the Linux-portable Expo path instead
20
+
21
+ ## Best bootstrap / init path
22
+
23
+ Conceptually, the right scaffold starts from the official Apple project shape:
24
+
25
+ 1. bootstrap on **macOS with Xcode** using the iOS **App** template in **Objective-C**
26
+ 2. keep the generated native app target, test target, shared scheme, plist, storyboard/resources, and Xcode project/workspace as the source of truth
27
+ 3. commit that generated baseline, then add only the minimum repo-local wrappers and portable checks needed for Linux-side verification
28
+ 4. on Linux, validate the committed Xcode surface; do **not** replace the Xcode bootstrap with a Linux-only generator and call it equivalent
29
+
30
+ Do **not**:
31
+
32
+ - invent a fake Linux-native Objective-C iOS bootstrap CLI
33
+ - treat GNUstep or generic clang Objective-C compilation as proof of an iOS app scaffold
34
+ - claim Linux can initialize, build, sign, or run the real iOS app target
35
+
36
+ If the repo contains shared portable code outside the app target, keep that code in a clearly separate portable module and test it honestly on Linux.
37
+
38
+ ## Runtime contract
39
+
40
+ - required Docker command: `docker compose up --build`
41
+ - required broad test command: `./run_tests.sh`
42
+ - both commands must be real and working
43
+ - `./run_app.sh` is usually **not** useful on Linux for this family
44
+ - native iOS build/run proof still requires a separate macOS/Xcode checkpoint
45
+ - prefer a one-shot verification/report flow over a fake long-running "app" container
46
+
47
+ ## What `docker compose up --build` should mean
48
+
49
+ For this family, `docker compose up --build` should mean:
50
+
51
+ - build and run a **Linux verification/support environment**, not a fake iOS runtime
52
+ - install pinned portable tools for static Xcode-project inspection (for example Ruby + `xcodeproj`)
53
+ - open the committed `.xcodeproj` and shared scheme and validate targets, product types, plist values, storyboard/resources, and Objective-C source presence
54
+ - write a stable host-visible verification report so the result is observable and repeatable
55
+
56
+ It must **not** mean:
57
+
58
+ - `xcodebuild` proof
59
+ - simulator or device runtime proof
60
+ - `.app`, `.ipa`, archive, signing, or App Store readiness proof
61
+ - CocoaPods integration proof on macOS
62
+
63
+ ## What `./run_tests.sh` should mean
64
+
65
+ `./run_tests.sh` is the honest Linux broad verification wrapper for this family.
66
+
67
+ It should run the portable checks Linux can really prove, such as:
68
+
69
+ - any real tests for shared portable modules when they exist
70
+ - at least one real test of the Linux verifier itself (for example, a negative-path check that missing scheme/project wiring fails)
71
+ - static validation of the committed Xcode project shape, shared scheme, plist/config files, storyboard/resources, and script wiring
72
+ - consistency checks for dependency/config metadata that can be inspected without Xcode
73
+
74
+ If no portable shared modules exist, `./run_tests.sh` should still be a real static-validation gate and should state clearly that native Objective-C app build/runtime proof requires macOS/Xcode.
75
+
76
+ It must never silently imply native iOS build success.
77
+
78
+ ## Is `./run_app.sh` useful?
79
+
80
+ Usually **no** on Linux.
81
+
82
+ Only add `./run_app.sh` when it is an honest handoff helper, for example:
83
+
84
+ - printing the exact macOS/Xcode next step
85
+ - opening or documenting the intended scheme/workspace handoff
86
+ - starting an adjacent non-iOS support surface that the repo genuinely needs
87
+
88
+ It must never pretend to launch the native iOS app from Linux.
89
+
90
+ In the strongest truthful baseline tested so far, omit `./run_app.sh` entirely because it adds no Linux proof.
91
+
92
+ ## Honest Linux proof boundary
93
+
94
+ Linux can honestly prove only the portable boundary, such as:
95
+
96
+ - repo shape and scaffold completeness
97
+ - that a committed Xcode project and shared scheme can be parsed and inspected from Linux
98
+ - shared non-app module tests when those modules are truly portable
99
+ - static Xcode-project/config validation
100
+ - the reproducibility of the Linux verification container itself
101
+
102
+ Linux cannot honestly prove:
103
+
104
+ - native Objective-C app compilation against the iOS SDK
105
+ - simulator behavior
106
+ - on-device behavior
107
+ - code signing
108
+ - archive/export quality
109
+ - App Store readiness
110
+
111
+ ## Minimal real test floor
112
+
113
+ At scaffold, include at least:
114
+
115
+ - one real static project/config validation step
116
+ - one real validation of the shared scheme / target wiring inside the committed Xcode project
117
+ - one real portable test when portable shared logic exists
118
+ - one real verifier test when no portable app logic exists yet
119
+ - one real `./run_tests.sh` path that fails on actual validation problems
120
+ - one honest README statement that macOS/Xcode is still required for native iOS proof
121
+
122
+ ## README floor
123
+
124
+ `README.md` must already state:
125
+
126
+ - scaffold status versus implemented scope
127
+ - this is a native Objective-C iOS scaffold, not the default Linux iOS family
128
+ - required Docker command: `docker compose up --build`
129
+ - broad test command: `./run_tests.sh`
130
+ - whether `./run_app.sh` exists and why
131
+ - what artifact/report `docker compose up --build` produces or what observable success condition it reaches
132
+ - the exact Linux proof boundary versus the required macOS/Xcode checkpoint
133
+
134
+ ## Common pitfalls
135
+
136
+ - pretending Linux can prove the native Objective-C iOS app target
137
+ - hand-rolling a non-Xcode starter and calling it equivalent to the official bootstrap path
138
+ - using static validation output wording that sounds like simulator or device proof
139
+ - adding `./run_app.sh` even though it adds no honest value
140
+ - leaving `./run_tests.sh` as a placeholder because Linux cannot run the app
141
+
142
+ ## Acceptance checklist
143
+
144
+ Scaffold is acceptable when:
145
+
146
+ - the official/bootstrap concept is documented as Xcode-on-macOS
147
+ - `docker compose up --build` gives a real Linux verification/support environment
148
+ - `./run_tests.sh` gives a real portable verification gate
149
+ - `./run_app.sh` is absent unless it adds honest handoff value
150
+ - the Linux proof boundary is documented clearly
151
+ - the family remains explicit opt-in and non-default
@@ -0,0 +1,188 @@
1
+ # Native iOS Swift Scaffold Playbook
2
+
3
+ Use this playbook only when the prompt explicitly requires a native Swift iOS app or the existing repo is already a native Swift iOS codebase.
4
+
5
+ ## Goal
6
+
7
+ Create an honest native iOS scaffold that:
8
+
9
+ - stays truly native Swift for the app target
10
+ - uses Linux only for the portable proof it can really provide
11
+ - does not fake Xcode, simulator, signing, or `.app` proof
12
+ - still gives the repo a real Docker baseline and a real broad test wrapper
13
+
14
+ ## Runtime contract
15
+
16
+ - required Docker command: `docker compose up --build`
17
+ - required broad test command: `./run_tests.sh`
18
+ - both commands must be real and working
19
+ - `./run_app.sh` is usually **not** useful on Linux and should stay optional
20
+ - do not claim native iOS runtime proof from Linux
21
+
22
+ ## Verified baseline notes
23
+
24
+ From a real Linux lab verification on 2026-04-15:
25
+
26
+ - the strongest honest baseline was a **partial-proof native Swift iOS scaffold**, not a fake native app build
27
+ - the verified Docker image used the official Swift Linux toolchain family (`swift:6.1-jammy`) only for the portable proof boundary
28
+ - `docker compose up --build -d --wait` reached a stable healthy state with one long-running verifier container and no published ports
29
+ - the healthy state was a passed proof report written to `artifacts/linux-proof-report.txt` plus `artifacts/linux-proof-report.json`
30
+ - the real Linux-verifiable work was: static validation of the checked-in Xcode project/scheme/package wiring plus `swift build` and `swift test` for a portable SwiftPM module
31
+ - the verified `./run_tests.sh` pattern was: start the Compose verifier, rerun `./container-verify.sh` via `docker compose exec`, then smoke-check the passed proof report
32
+ - `./run_app.sh` was only acceptable as a macOS/Xcode handoff helper that opens or points at the `.xcodeproj`; it must not imply Linux can launch the native app
33
+ - the experimentally verified proof boundary is still partial: Linux can prove portable Swift code + static native repo shape, but not `xcodebuild`, Simulator runtime, signing, or archive/export
34
+
35
+ ## Official/bootstrap/init path
36
+
37
+ - use the official Xcode **App** template in **Swift** as the conceptual app bootstrap
38
+ - choose **SwiftUI App** when the prompt is open; keep **UIKit** only when the prompt or repo requires it
39
+ - treat Xcode version, iOS SDK selection, signing setup, simulator choice, and archive behavior as a **macOS/Xcode checkpoint**, not a Linux scaffold promise
40
+ - if scaffold automation is needed from Linux, create the repo shape and portable Swift package surfaces that match the chosen app structure; do **not** pretend there is a stable official Linux CLI for full native iOS app generation
41
+ - when shared logic belongs outside the app target, prefer a real Swift Package Manager module so Linux can prove something portable
42
+
43
+ ## Safe default shape
44
+
45
+ Prefer this split when the prompt leaves room:
46
+
47
+ - native iOS app target owned by Xcode/macOS
48
+ - one or more portable SwiftPM modules for shared domain, model, formatting, validation, or networking logic
49
+ - tests for those SwiftPM modules that run on Linux with `swift test`
50
+
51
+ Concrete verified baseline shape:
52
+
53
+ - `Package.swift` at the repo root for the portable shared module
54
+ - `Sources/<ModuleName>/` and `Tests/<ModuleName>Tests/` for real Linux SwiftPM proof
55
+ - `App/` (or similarly clear app-source folder) containing SwiftUI entry files meant for Xcode
56
+ - `<AppName>.xcodeproj/project.pbxproj`
57
+ - `<AppName>.xcodeproj/project.xcworkspace/contents.xcworkspacedata`
58
+ - `<AppName>.xcodeproj/xcshareddata/xcschemes/<AppName>.xcscheme`
59
+ - a checked-in local Swift package reference from the Xcode project to the portable module when shared logic exists
60
+
61
+ If the repo has only an app target and no portable module yet, keep the documentation honest that Linux can validate repo shape only until a macOS/Xcode checkpoint happens.
62
+
63
+ ## What `docker compose up --build` means
64
+
65
+ For this family on Linux, `docker compose up --build` must mean a **real partial-proof baseline**, not a fake iOS build.
66
+
67
+ Acceptable meaning:
68
+
69
+ 1. build a pinned Swift Linux container for portable verification
70
+ 2. run any portable `swift build` / `swift test` work for SwiftPM modules that actually exist
71
+ 3. run static repo-shape validation for the native iOS surface, such as checking that the expected Xcode project/workspace files, schemes, manifest files, and portable module wiring exist
72
+ 4. expose a small stable report/health surface if Compose needs a long-running healthy state after verification
73
+
74
+ Concrete verified pattern:
75
+
76
+ 1. use one verifier service based on the official Swift Linux image family
77
+ 2. bind-mount the workspace into the container
78
+ 3. persist Swift build/cache directories with named volumes so reruns avoid unnecessary recompilation
79
+ 4. run a single repo-local verification script that performs static Xcode-shape checks and `swift build` + `swift test`
80
+ 5. write a repo-visible proof artifact under `artifacts/`
81
+ 6. keep the container alive after success so Compose health reflects a verified baseline instead of an exited process
82
+ 7. prefer zero published host ports unless a report/support surface truly benefits from one
83
+
84
+ Unacceptable meaning:
85
+
86
+ - claiming the container built an iOS `.app`
87
+ - claiming simulator success
88
+ - claiming CocoaPods integration quality on macOS
89
+ - claiming code-signing, archive, or App Store readiness
90
+
91
+ If no portable SwiftPM modules exist yet, the Docker path must still do honest static validation and report that native app build proof is blocked on macOS/Xcode.
92
+
93
+ ## What `./run_tests.sh` means
94
+
95
+ `./run_tests.sh` is the broad portable verification wrapper for Linux.
96
+
97
+ It should cover the strongest honest Linux proof available, typically:
98
+
99
+ - `swift test` for portable SwiftPM modules when present
100
+ - `swift build` for portable modules when that adds useful build-shape proof
101
+ - lint or formatting checks when the repo already uses a real portable Swift tool for them
102
+ - static validation that the native iOS project shape and portable module references are present and coherent
103
+
104
+ Concrete verified execution pattern:
105
+
106
+ 1. `docker compose up --build -d --wait`
107
+ 2. reuse the same running verifier container with `docker compose exec`
108
+ 3. rerun the repo-local verification script there
109
+ 4. smoke-check the generated proof report under `artifacts/`
110
+ 5. tear the stack down at the end of the wrapper script
111
+
112
+ If no portable testable module exists yet, `./run_tests.sh` must say so plainly and fail or partial-out honestly according to project policy; it must not silently pass by pretending the native app was tested.
113
+
114
+ ## Is `./run_app.sh` useful?
115
+
116
+ Usually **no** on Linux.
117
+
118
+ Only add `./run_app.sh` when it clearly helps with a documented macOS/Xcode handoff, for example:
119
+
120
+ - detecting macOS and opening the Xcode project/workspace
121
+ - printing the exact simulator or scheme command a macOS user should run next
122
+ - routing to a documented local bootstrap step that still tells the truth about the proof boundary
123
+
124
+ The experimentally verified Swift baseline supports this pattern well:
125
+
126
+ - on Linux, print the proof boundary and the exact `.xcodeproj` handoff path
127
+ - on macOS, open the checked-in `.xcodeproj` with `xed` or `open`
128
+
129
+ Do not add `./run_app.sh` just to wrap a no-op or to imply Linux can run the app.
130
+
131
+ ## Honest Linux proof boundary
132
+
133
+ Linux can honestly prove only these things for this family:
134
+
135
+ - portable SwiftPM modules compile
136
+ - portable SwiftPM tests pass
137
+ - the native iOS repo shape exists and matches the documented scaffold contract
138
+ - shared code packaging and references are wired coherently enough for a later macOS/Xcode checkpoint
139
+
140
+ Linux does **not** prove:
141
+
142
+ - Xcode build success
143
+ - SwiftUI/UIKit rendering in an iOS simulator
144
+ - CocoaPods/SPM integration behavior inside Xcode
145
+ - provisioning/signing
146
+ - archive/export behavior
147
+ - App Store readiness
148
+
149
+ ## Minimal real test floor
150
+
151
+ At scaffold, include at least:
152
+
153
+ - one real portable Swift test when a portable SwiftPM module exists
154
+ - one real portable build or lint/format verification path
155
+ - one honest Docker-backed Linux verification path behind `docker compose up --build`
156
+ - one explicit README statement that native app build/runtime proof still requires macOS/Xcode
157
+
158
+ If there is truly no portable module yet, replace the first two bullets with strong static validation plus explicit documentation that the family is non-default on Linux because portable proof is narrow.
159
+
160
+ ## README floor
161
+
162
+ `README.md` must already state:
163
+
164
+ - scaffold status versus implemented scope
165
+ - required Docker command: `docker compose up --build`
166
+ - broad test command: `./run_tests.sh`
167
+ - whether `./run_app.sh` exists and why
168
+ - that native iOS app build/runtime proof requires a separate macOS/Xcode checkpoint
169
+ - exactly what Linux does and does not prove for this repo
170
+
171
+ ## Common pitfalls
172
+
173
+ - pretending `swift build` on Linux built the iOS app target
174
+ - implying simulator or archive proof without macOS
175
+ - leaving `docker compose up --build` empty because full native proof is unavailable
176
+ - adding `./run_app.sh` as a decorative no-op
177
+ - hiding that this family is non-default on Linux
178
+
179
+ ## Acceptance checklist
180
+
181
+ Scaffold is acceptable when:
182
+
183
+ - the family is treated as explicit opt-in, not the Linux default
184
+ - `docker compose up --build` performs real portable verification honestly
185
+ - `./run_tests.sh` performs the broad portable verification honestly
186
+ - `./run_app.sh` is omitted unless it adds a truthful macOS/Xcode handoff
187
+ - README documents the Linux proof boundary clearly
188
+ - no fake native iOS build/runtime claims are made