pass_typer: Improve matching of destination (still doesn't handle command)
This commit is contained in:
parent
6c66988950
commit
2330bde957
@ -129,7 +129,9 @@ def select_and_type(server_match: ServerMatch) -> None:
|
||||
|
||||
window_name = cmd(["xdotool", "getactivewindow", "getwindowname"]).stdout.strip()
|
||||
|
||||
ssh_match = re.search(":([^ ]+=[^ ]* )*(mosh|ssh) (?P<destination>.*)", window_name)
|
||||
ssh_match = re.search(
|
||||
":([^ ]+=[^ ]* )*(mosh|ssh) .* (?P<destination>[^ ]*)$", window_name
|
||||
)
|
||||
if ssh_match:
|
||||
server_match = ServerMatch.from_destination(ssh_match.group("destination"))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user