Skip to content

feat(publish): license + advertise tvos/watchos targets#4

Merged
proggeramlug merged 1 commit into
mainfrom
feat/tvos-watchos-publish
Jun 13, 2026
Merged

feat(publish): license + advertise tvos/watchos targets#4
proggeramlug merged 1 commit into
mainfrom
feat/tvos-watchos-publish

Conversation

@proggeramlug

@proggeramlug proggeramlug commented Jun 13, 2026

Copy link
Copy Markdown
Contributor

What

Hub half of tvOS + watchOS App Store publishing. Lets pro-tier licenses publish to tvOS and watchOS, and reports both on the public targets status page.

Companion: perry CLI PR (PerryTS/perry#5085) and worker deploy patches.

Changes (src/main.ts)

  • Pro-tier platform allowlists (registerLicense + account-tier update): add tvos, watchos.
  • rebuildTargetsJson: add tvos/watchos to the known/labels arrays and bump the loop bound so they appear in targets.json when a worker advertises them.

Routing / signing — no change needed

tvOS and watchOS sign/package exactly like iOS, so they ride the existing two-phase flow: the linux worker tags the unsigned bundle ios-precompiled and reports needs_finishing: "ios", and the hub re-queues ios-sign for the macOS ship worker. That logic is suffix-generic and already handles this; no new *-sign capability or verify-target mapping is added (tvOS already ships without one).

Test

perry check src/main.ts passes.

Summary by CodeRabbit

  • New Features
    • Pro tier licenses now support additional platforms: tvOS and watchOS, alongside existing macOS, iOS, Android, Windows, and Linux support.

Pro-tier licenses now include tvos + watchos, and rebuildTargetsJson
reports them on the public targets status page. Routing/signing reuse the
existing ios-precompiled -> ios-sign path (tvOS/watchOS sign exactly like
iOS), so no new sign capability is needed.

Part of tvOS + watchOS (arm64_32) App Store publishing support.
@coderabbitai

coderabbitai Bot commented Jun 13, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

This PR expands Pro-tier license support from 5 platforms to 7 by adding tvOS and watchOS. Three locations in src/main.ts are updated: license registration defaults, account tier sync logic, and target capability discovery. All changes are platform-focused and self-contained within a single file.

Changes

Platform Support Expansion

Layer / File(s) Summary
Pro license platform defaults
src/main.ts
registerLicense() and /api/v1/account/update both now assign tvOS and watchOS to the default platform set for Pro-tier licenses.
Supported targets capability expansion
src/main.ts
rebuildTargetsJson() expands its known platform set from 5 to 7 platforms and adjusts iteration logic to include tvOS and watchOS capability coverage.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 Two platforms hop through our gates,
tvOS and watchOS await,
Pro licenses now span them all—
From phone to watch, we answer the call!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: adding tvOS and watchOS platform support to licenses and the targets status advertisement system.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/tvos-watchos-publish

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
src/main.ts (1)

713-713: ⚡ Quick win

Consider using array length instead of hardcoded bound.

The loop bound 7 is hardcoded and must be manually updated if platforms are added or removed. Using known.length would make this more maintainable.

♻️ Proposed refactor
-  for (let ki = 0; ki < 7; ki++) {
+  for (let ki = 0; ki < known.length; ki++) {
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/main.ts` at line 713, The for-loop using a hardcoded bound "7" should use
the actual array length to stay correct when platforms change: replace the loop
header for (let ki = 0; ki < 7; ki++) with a bound derived from the platforms
array (use known.length) so the loop iterates over known.length items; update
any dependent logic that assumes exactly 7 iterations to operate based on
known.length as well (identify the loop by the variable name ki and the array
known in the surrounding code).
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@src/main.ts`:
- Line 713: The for-loop using a hardcoded bound "7" should use the actual array
length to stay correct when platforms change: replace the loop header for (let
ki = 0; ki < 7; ki++) with a bound derived from the platforms array (use
known.length) so the loop iterates over known.length items; update any dependent
logic that assumes exactly 7 iterations to operate based on known.length as well
(identify the loop by the variable name ki and the array known in the
surrounding code).

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: a741a903-6af9-4483-b7cc-d589e7de8d1a

📥 Commits

Reviewing files that changed from the base of the PR and between e8bc3de and 8a30a3a.

📒 Files selected for processing (1)
  • src/main.ts

@proggeramlug proggeramlug merged commit daef07c into main Jun 13, 2026
1 check passed
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