Skip to content

refactor(tuist): rename app dir to sudoku and project to game - #222

Merged
wei18 merged 2 commits into
mainfrom
refactor/rename-app-to-sudoku
May 31, 2026
Merged

wei18 merged 2 commits into
mainfrom
refactor/rename-app-to-sudoku

Conversation

@wei18

@wei18 wei18 commented May 31, 2026

Copy link
Copy Markdown
Owner

Summary

  • Rename `App/` → `Sudoku/` (all 11 contents move via `git mv`).
  • Rename Tuist project from `Sudoku` to `Game` (multi-target umbrella) — generated artifacts become `Game.xcodeproj` + `Game.xcworkspace`. The Sudoku target keeps its name, bundle id `com.wei18.sudoku`, and scheme.
  • Update `Project.swift` (5 paths + project name + header comment), `license_plist.yml` outputPath, `.gitignore` Settings.bundle entry, `.mise.toml` / ci scripts / README / Package.swift doc comments.

Context — RFC

PR C of 4 preparing the repo to host a second app (Minesweeper) alongside Sudoku in the same Tuist project. See `meetings/2026-05-31_minesweeper-rfc.md`.

Design

  • Single Project.swift, multi-target (per user direction): no separate `Minesweeper/Project.swift`. PR D adds `minesweeperTarget` alongside `sudokuTarget` in the same root manifest. No `Workspace.swift` needed — Tuist generates implicit `Game.xcworkspace` from the project name.
  • Target name preserved: the Sudoku app target stays `Sudoku` so no certificate / provisioning profile / ASC churn. Only the umbrella project name changes.

⚠️ Post-merge action (user-owned)

  • Xcode Cloud workflows in App Store Connect reference an .xcworkspace path. Today they point at `Sudoku.xcworkspace` (implicit). After this PR ships, that file no longer exists; the workspace is now `Game.xcworkspace`. Each workflow needs its primary project re-pointed in the ASC UI.
  • Local Xcode "Open Recent" entries break for every team member (acceptable; no data lost — reopen `Game.xcworkspace` once).

Verification

  • `tuist generate --no-open` succeeds; produces `Game.xcodeproj` + `Game.xcworkspace` at repo root
  • `tuist build Sudoku --platform iOS` → Build Succeeded
  • CI: lint:swift_strict, iOS + macOS test suites, snapshot tests

Review

Reviewed by Code Reviewer subagent: APPROVE_WITH_NITS → all 3 nits applied (README L6/L28/L51, ci_post_clone L37, "symlink → copy" wording across Package.swift + 3 test files).

🤖 Generated with Claude Code

wei18 and others added 2 commits May 31, 2026 21:56
Prep for hosting a second app (Minesweeper, planned in PR D / RFC
`meetings/2026-05-31_minesweeper-rfc.md`) as a sibling target under
the same Tuist project umbrella. The Sudoku TARGET keeps its name,
bundle id `com.wei18.sudoku`, and scheme; only the umbrella project
becomes `Game` and the app's source/resource dir becomes `Sudoku/`.

Path renames
------------
- App/                → Sudoku/                (all 11 contents move via git mv)
- Project.swift `App/X` paths → `Sudoku/X`     (5 occurrences)
- license_plist.yml outputPath                 (App/Resources → Sudoku/Resources)
- .gitignore Settings.bundle entry             (same rename)

Project rename
--------------
- `Project(name: "Sudoku")` → `Project(name: "Game")`
- Generated artifacts: Sudoku.xcodeproj → Game.xcodeproj, similarly .xcworkspace
- Heads-up: Xcode Cloud workflows in App Store Connect reference the
  .xcworkspace path → needs user reconfig post-merge (user-owned).
- Local Xcode "Open Recent" entries break for everyone (acceptable).

Doc comment updates
-------------------
.mise.toml / ci_scripts/ci_post_clone.sh / Packages/SudokuKit/Package.swift
/ Packages/SudokuKit/Tests/AppCompositionTests/{L10nTests,PrivacyManifestTests}.swift
— all reference the path or generated artifact name.

LiveAdMobBridge.swift comments mentioning `App/Info.plist` are intentionally
NOT touched here (PR B deletes those lines as part of the Monetization
config refactor — resolving on rebase rather than touching the same lines
in two PRs).

Verification
------------
- `tuist generate --no-open` → produces `Game.xcodeproj` + `Game.xcworkspace`
- `tuist build Sudoku --platform iOS` → Build Succeeded

PR C of 4 (A: persistence config #219 ✓ ; B: monetization config #220 ⏳ ;
C: this; D: Minesweeper skeleton + new packages).

Co-Authored-By: Claude Opus 4.7 <[email protected]>
Three follow-ups to PR C's rename sweep flagged by Code Reviewer:

1. README.md L6/L28/L51 — three stale `App/` references in user-facing
   doc updated to `Sudoku/` + line 51 mentions Game umbrella for future
   Minesweeper sibling.
2. ci_scripts/ci_post_clone.sh L37 — workspace name reference
   `Sudoku.xcworkspace` → `Game.xcworkspace`.
3. Packages/SudokuKit/Package.swift L170 + L10nTests.swift / L10nCompletenessTests.swift /
   PrivacyManifestTests.swift comments — claim "via symlinks under
   Resources/" was stale; actual implementation uses literal copies
   (with `.xcstrings` → `.json` extension hack so the xcstrings
   compiler skips it). Corrected.

Co-Authored-By: Claude Opus 4.7 <[email protected]>
@wei18
wei18 merged commit e1ca517 into main May 31, 2026
3 of 5 checks passed
@wei18
wei18 deleted the refactor/rename-app-to-sudoku branch May 31, 2026 15:34
wei18 added a commit that referenced this pull request May 31, 2026
…ackages (#223)

* feat(minesweeper): add app target skeleton + MinesweeperCoreKit/Kit packages

Closes the 4-PR Minesweeper-prep arc (A: persistence config #219 ✓; B:
monetization config #220 ✓; C: rename + project→Game #222 ✓; D: this).

Adds a second app target `Minesweeper` (bundleId `com.wei18.minesweeper`)
inside the existing Game project, plus two new local SwiftPM packages
mirroring the Sudoku{CoreKit,Kit} shape:

- `Packages/MinesweeperCoreKit/` — pure-Swift game core, single module
  `MinesweeperEngine` (placeholder `public struct`) + smoke test
- `Packages/MinesweeperKit/` — UI + composition, modules `MinesweeperUI`
  (placeholder `MinesweeperRootView` "Hello, Minesweeper" screen) and
  `MinesweeperAppComposition` (`bootRootView()` factory)

App target dir `Minesweeper/` mirrors `Sudoku/`:
- `MinesweeperApp.swift` (@main → `MinesweeperAppComposition.bootRootView()`)
- `Info.plist` (no AdMob keys yet)
- `Minesweeper.entitlements` — separate iCloud container
  `iCloud.com.wei18.minesweeper`, app-sandbox, GameKit
- `Assets.xcassets/` — placeholder (copied from Sudoku; flip when
  Minesweeper has its own AppIcon art)
- `Resources/Localizable.xcstrings` — empty `en` catalog
- `Resources/PrivacyInfo.xcprivacy` — copied verbatim from Sudoku
  (anticipates AdMob wiring; revisit when monetization actually lands)
- `Minesweeper.xctestplan` — pointed at `MinesweeperEngineTests` only

`Project.swift`:
- Adds `minesweeperTarget` (same `appTargetSettings` icon-name override)
- Adds `Packages/MinesweeperKit` to `packages:`
- Adds Minesweeper scheme alongside the existing Sudoku scheme

Module names (`MinesweeperEngine` / `MinesweeperUI` / `MinesweeperAppComposition`)
are namespaced to avoid colliding with SudokuCoreKit's `GameState` and
SudokuKit's `SudokuUI` / `AppComposition` in the same Xcode project's
package graph.

Verified
--------
- `tuist generate --no-open` → produces `Game.xcworkspace` with both schemes
- `tuist build Sudoku --platform iOS` → green (regression)
- `tuist build Minesweeper --platform iOS` → green
- `swift test --package-path Packages/MinesweeperCoreKit` → 1/1 pass

Follow-ups (filed as separate work, NOT part of this skeleton)
- Provision `iCloud.com.wei18.minesweeper` CloudKit container in Dashboard
- Wire Minesweeper's own AdMob banner + IAP product IDs (consumes the
  PR B parameterization)
- Wire `LivePersistence` with a `PrivateCKConfig.minesweeper` constant
  (consumes the PR A parameterization)
- Replace placeholder MinesweeperEngine with real mine placement +
  flood-fill + win/lose detection
- Replace placeholder AppIcon with Minesweeper art

Co-Authored-By: Claude Opus 4.7 <[email protected]>

* docs(minesweeper): address CR nits

1. PrivacyInfo.xcprivacy header — prepend Minesweeper PR D context note
   explaining the verbatim copy + flip condition (no XML change).
2. MinesweeperEngine.swift — drop unused `internal import Foundation`.
3. Project.swift header — generalize the bundle-id / deployment-target
   bullet to cover both Sudoku and Minesweeper targets.

Co-Authored-By: Claude Opus 4.7 <[email protected]>

---------

Co-authored-by: Claude Opus 4.7 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant