1010from pathlib import Path
1111
1212
13- REQUIRED_BINARIES = {
13+ REQUIRED_PUBLIC_COMMANDS = {
14+ "turtleterm" ,
15+ "turtleterm-mux-server" ,
16+ "turtle-term" ,
17+ "turtle-agentd" ,
18+ "turtle-agentctl" ,
19+ "turtle-tmux" ,
20+ "sourceos-term" ,
21+ }
22+
23+ REQUIRED_PRIVATE_RUNTIME = {
1424 "wezterm" ,
1525 "wezterm-gui" ,
1626 "wezterm-mux-server" ,
17- "turtle-term" ,
18- "sourceos-term" ,
1927}
2028
2129REQUIRED_TOP_LEVEL_SUFFIXES = {
2230 "LICENSE.md" ,
2331 "README.md" ,
24- "UPSTREAM_WEZTERM_README .md" ,
32+ "THIRD_PARTY_NOTICES .md" ,
2533}
2634
2735
@@ -75,22 +83,28 @@ def main() -> int:
7583 raise SystemExit ("unexpected manifest schema" )
7684 if manifest .get ("product" ) != "TurtleTerm" :
7785 raise SystemExit ("unexpected manifest product" )
78- if manifest .get ("engine" ) != "WezTerm" :
79- raise SystemExit ("unexpected manifest engine" )
8086 if manifest .get ("archive" ) != archive .name :
8187 raise SystemExit ("manifest archive name does not match" )
8288 if manifest .get ("archive_sha256" ) != archive_hash :
8389 raise SystemExit ("manifest archive hash does not match" )
90+ if manifest .get ("runtime" ) != "private-terminal-runtime" :
91+ raise SystemExit ("manifest runtime must be private-terminal-runtime" )
8492
85- binaries = set (manifest .get ("binaries " , []))
86- missing_manifest_bins = REQUIRED_BINARIES - binaries
87- if missing_manifest_bins :
88- raise SystemExit (f"manifest missing binaries : { sorted (missing_manifest_bins )} " )
93+ public_commands = set (manifest .get ("public_commands " , []))
94+ missing_commands = REQUIRED_PUBLIC_COMMANDS - public_commands
95+ if missing_commands :
96+ raise SystemExit (f"manifest missing public commands : { sorted (missing_commands )} " )
8997
9098 members = archive_members (archive )
91- for binary in REQUIRED_BINARIES :
92- if not suffix_present (members , f"bin/{ binary } " ):
93- raise SystemExit (f"archive missing binary: { binary } " )
99+ for command in REQUIRED_PUBLIC_COMMANDS :
100+ if not suffix_present (members , f"bin/{ command } " ):
101+ raise SystemExit (f"archive missing public command: { command } " )
102+
103+ for runtime in REQUIRED_PRIVATE_RUNTIME :
104+ if not suffix_present (members , f"libexec/turtle-term/{ runtime } " ):
105+ raise SystemExit (f"archive missing private runtime binary: { runtime } " )
106+ if suffix_present (members , f"bin/{ runtime } " ):
107+ raise SystemExit (f"private runtime binary exposed on product PATH: { runtime } " )
94108
95109 for suffix in REQUIRED_TOP_LEVEL_SUFFIXES :
96110 if not suffix_present (members , suffix ):
@@ -100,6 +114,10 @@ def main() -> int:
100114 raise SystemExit ("archive missing TurtleTerm profile" )
101115 if not any ("share/turtle-term/sourceos/" in member for member in members ):
102116 raise SystemExit ("archive missing SourceOS documentation" )
117+ if not any ("share/turtle-term/skills/" in member for member in members ):
118+ raise SystemExit ("archive missing TurtleTerm skill manifests" )
119+ if not any ("share/turtle-term/brand/" in member for member in members ):
120+ raise SystemExit ("archive missing TurtleTerm brand assets" )
103121
104122 print (f"verified { archive .name } " )
105123 return 0
0 commit comments