diff --git a/harbor/cli.py b/harbor/cli.py index ec4444d..ace3961 100644 --- a/harbor/cli.py +++ b/harbor/cli.py @@ -399,6 +399,12 @@ def main(argv=None): if not agent: agent = project.identity_for(os.getcwd()) source = "working directory" if agent else None + else: + # a second session of the same app (Codex2 in the Codex app) copies the app's shared `--as Codex` + # instructions; its working folder says who it is + session = project.session_identity(agent, os.getcwd()) + if session != agent: + agent, source = session, f"working directory (same app as {agent})" recorded = []