fix(lib): use symlink-safe realpath comparison for workspace cwd matching in find_workspace_uuid
This commit is contained in:
@@ -1229,7 +1229,8 @@ def emit(u):
|
|||||||
# Fetch all sessions matching this workspace
|
# Fetch all sessions matching this workspace
|
||||||
sessions = []
|
sessions = []
|
||||||
for s in d.get('herdr_sessions', []):
|
for s in d.get('herdr_sessions', []):
|
||||||
if isinstance(s, dict) and (s.get('pane') or {}).get('cwd') == ws:
|
s_cwd = (s.get('pane') or {}).get('cwd', '') if isinstance(s, dict) else ''
|
||||||
|
if s_cwd and (s_cwd == ws or os.path.realpath(s_cwd) == os.path.realpath(ws)):
|
||||||
sessions.append(s)
|
sessions.append(s)
|
||||||
|
|
||||||
if target:
|
if target:
|
||||||
|
|||||||
Reference in New Issue
Block a user