feat(local-service): allow exact worktree migration
This commit is contained in:
@@ -28,6 +28,14 @@ def main() -> int:
|
||||
parser = argparse.ArgumentParser()
|
||||
parser.add_argument("action", choices=("plan", "apply", "status"))
|
||||
parser.add_argument("--repository-root", type=Path, required=True)
|
||||
parser.add_argument(
|
||||
"--expected-current-repository-root",
|
||||
type=Path,
|
||||
help=(
|
||||
"authorize migration only from this exact installed WorkingDirectory; "
|
||||
"cross-repository plans remain denied when omitted"
|
||||
),
|
||||
)
|
||||
parser.add_argument(
|
||||
"--agent-path",
|
||||
type=Path,
|
||||
@@ -43,6 +51,7 @@ def main() -> int:
|
||||
plan = plan_mission_core_launch_agent(
|
||||
repository_root=arguments.repository_root,
|
||||
agent_path=arguments.agent_path,
|
||||
expected_current_repository_root=arguments.expected_current_repository_root,
|
||||
)
|
||||
if arguments.action == "plan":
|
||||
print(json.dumps(plan.to_dict(), indent=2, sort_keys=True))
|
||||
|
||||
Reference in New Issue
Block a user