+
    „WÝj
  ã                  óÀ   € R t ^ RIHt ^ RIt^ RIt^ RIt^ RIHt ]P                  ! ]	4      t
Rt]P                  ! 4       tR R ltR R ltR	 R
 ltR R ltR R ltR# )a¿  Per-profile registry of every repository Hermes has created a worktree in.

The 6-hourly cron sweep (``cron.scheduler._worktree_maintenance_repos``) only knew the Hermes
checkout and cron job workdirs, so trees made by ``hermes -w`` / ``/worktree new`` / subagent
isolation / the Desktop git pane in any other repo were never swept. Each creation path records
its repo here; the sweep unions this list with its other sources.

The file lives under the ACTIVE profile's home (``get_hermes_home()``), so one profile's sweep
never visits another profile's repos. Writes are atomic under a cross-process lock; entries whose
repo no longer exists are dropped on every read-modify-write and filtered on read.
)ÚannotationsN)ÚPathzworktree_repos.jsonc               ó   € V ^8„  d   QhRR/# )é   Úreturnr   © )Úformats   "ÚPC:\Users\johnn\AppData\Local\hermes\hermes-agent\hermes_cli\worktree_registry.pyÚ__annotate__r
      s   € ÷ .ñ .�tñ .ó    c                 ó2   € ^ RI Hp  V ! 4       \        ,          # )é    ©Úget_hermes_home)Úhermes_constantsr   Ú_REGISTRY_NAMEr   s    r	   Úregistry_pathr      s   € Ý0ÙÓœ~Õ-Ð-r   c               ó    € V ^8„  d   QhRRRR/# )r   ÚrepoÚstrr   Úboolr   )r   s   "r	   r
   r
      s   € ÷ *ñ *�sð *˜tñ *r   c                óB   € \        V 4      R ,          P                  4       # )z.git)r   Úexists)r   s   &r	   Ú_repo_existsr      s   € Ü�‹J˜Õ×'Ñ'Ó)Ð)r   c               ó    € V ^8„  d   QhRRRR/# )r   Úpathr   r   ú	list[str]r   )r   s   "r	   r
   r
   #   s   € ÷ ]ñ ]�ð ]˜ñ ]r   c                óÞ   € ^ RI Hp V! V 4      P                  R4      p\        V\        4      '       d5   V Uu. uF'  p\        V\
        4      '       g   K  V'       g   K%  VNK)  	  up# . # u upi )r   )Úread_json_or_emptyÚrepos)Úutilsr   ÚgetÚ
isinstanceÚlistr   )r   r   r   Úrs   &   r	   Ú_readr%   #   sS   € Ý(Ù˜tÓ$×(Ñ(¨Ó1€EÜ=GÈÌt×=TÒ=T‘uÓ9‘u�!¤
¨1¬c× 2ŒA´q�AˆA‘uÑ9Ð\ÐZ\Ð\ùÒ9s   ¸A*ÁA*ÁA*c               ó   € V ^8„  d   QhRR/# )r   r   r   r   )r   s   "r	   r
   r
   )   s   € ÷ ñ ˜)ñ r   c                 óÎ   €  \        \        4       4       U u. uF  p \        V 4      '       g   K  V NK  	  up # u up i   \         d    \        P                  RRR7       . u # i ; i)zKRegistered repo roots that still exist (read-only; never creates the file).zworktree registry read failedT©Úexc_info)r%   r   r   Ú	ExceptionÚloggerÚdebug)r$   s    r	   Úregistered_reposr-   )   sU   € ðÜ ¤£Ô1ÓEÑ1�a´\À!·_—�Ñ1ÑEÐEùÒEøÜô Ü�‰Ð4¸tˆÔDØŠ	ðús   ‚= —8¯8µ= ¸= ½$A$Á#A$c               ó   € V ^8„  d   QhRR/# )r   r   ÚNoner   )r   s   "r	   r
   r
   2   s   € ÷ Yñ Y tñ Yr   c           	     ó˜  € V '       g   R#  ^ RI Hp ^ RIHp \        P
                  P                  \        V 4      4      p\        4       pV! VP                  VP                  R,           4      \        RR4      ;_uu_ 4        \        V4      p\        P                  V4       Uu. uF  p\        V4      '       g   K  VNK  	  ppW79   d   Wu8X  d    RRR4       R# W79  d   VP!                  V4       V! VR^RV/4       RRR4       R# u upi   + '       g   i     R# ; i  \"         d    \$        P'                  R	T R
R7        R# i ; i)zHRemember *repo_root* as a repo with Hermes-made worktrees. Never raises.N)Ú
_file_lock)Úatomic_json_writez.lockg      @z0Timed out waiting for the worktree registry lockÚversionr   z&worktree registry update failed for %sTr(   )Úhermes_cli.authr1   r    r2   Úosr   Úrealpathr   r   Ú	with_nameÚnameÚ_holderr%   ÚdictÚfromkeysr   Úappendr*   r+   r,   )Ú	repo_rootr1   r2   r   r   Úcurrentr$   Úkepts   &       r	   Úrecord_worktree_repor@   2   s  € çÙðYÝ.Ý+ä�w‰w×Ñ¤ I£Ó/ˆÜ‹ˆÙ˜Ÿ™ t§y¡y°7Õ':Ó;¼WÀcØJ÷Lõ Lä˜D“kˆGÜ#Ÿ}™}¨WÔ5ÓIÑ5˜!¼Àa¿—A�AÑ5ˆDÐIØŒ| ¤Ø÷Lñ Lð ÔØ—‘˜DÔ!Ù˜d Y°°7¸DÐ$AÔB÷Lñ Lùò J÷L÷ Lð Lûô ô YÜ�‰Ð=¸yÐSWˆ×XðYúsT   ŒA5D" Â#DÂ$D	Â<D	ÃDÃD" Ã$DÃ?D" Ä	DÄD	ÄD" ÄD" Ä"#E	ÅE	)Ú__doc__Ú
__future__r   Úloggingr5   Ú	threadingÚpathlibr   Ú	getLoggerÚ__name__r+   r   Úlocalr9   r   r   r%   r-   r@   r   r   r	   Ú<module>rI      sW   ðñ
õ #ã Û 	Û Ý à	×	Ò	˜8Ó	$€à&€Ø
�/Š/Ó
€õ.õ
*õ]õ÷Yr   