summaryrefslogtreecommitdiff
path: root/accounts/gkleen@sif/xmonad/lib/XMonad/Prompt
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2021-05-15 15:27:19 +0200
committerGregor Kleen <gkleen@yggdrasil.li>2021-05-15 15:27:19 +0200
commit1514c30e46768eb978996660ad46ca8e48cef5b7 (patch)
treec27da4992f00b4c7372020c367e8560d2355cfc7 /accounts/gkleen@sif/xmonad/lib/XMonad/Prompt
parent9dddbe15c421b9f62cddee6f8cc4147f9d40cd86 (diff)
downloadnixos-1514c30e46768eb978996660ad46ca8e48cef5b7.tar
nixos-1514c30e46768eb978996660ad46ca8e48cef5b7.tar.gz
nixos-1514c30e46768eb978996660ad46ca8e48cef5b7.tar.bz2
nixos-1514c30e46768eb978996660ad46ca8e48cef5b7.tar.xz
nixos-1514c30e46768eb978996660ad46ca8e48cef5b7.zip
...
Diffstat (limited to 'accounts/gkleen@sif/xmonad/lib/XMonad/Prompt')
-rw-r--r--accounts/gkleen@sif/xmonad/lib/XMonad/Prompt/MySsh.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/accounts/gkleen@sif/xmonad/lib/XMonad/Prompt/MySsh.hs b/accounts/gkleen@sif/xmonad/lib/XMonad/Prompt/MySsh.hs
index c85d0f92..729941aa 100644
--- a/accounts/gkleen@sif/xmonad/lib/XMonad/Prompt/MySsh.hs
+++ b/accounts/gkleen@sif/xmonad/lib/XMonad/Prompt/MySsh.hs
@@ -80,9 +80,12 @@ moshCmd' p c = concat
80 , " -- " 80 , " -- "
81 , cCommand c 81 , cCommand c
82 ] 82 ]
83inTmux c 83inTmux Nothing c
84 | null $ cCommand c = c { cCommand = "tmux new-session" } 84 | null $ cCommand c = c { cCommand = "tmux new-session" }
85 | otherwise = c { cCommand = "tmux new-session \"" ++ (cCommand c) ++ "\"" } 85 | otherwise = c { cCommand = "tmux new-session \"" ++ (cCommand c) ++ "\"" }
86inTmux (Just h) c
87 | null $ cCommand c = c { cCommand = "tmux new-session -As " <> h }
88 | otherwise = c { cCommand = "tmux new-session \"" ++ (cCommand c) ++ "\"" }
86withEnv :: [(String, String)] -> Conn -> Conn 89withEnv :: [(String, String)] -> Conn -> Conn
87withEnv envs c = c { cCommand = "env" ++ (concat $ map (\(n, v) -> ' ' : (n ++ "=" ++ v)) envs) ++ " " ++ (cCommand c) } 90withEnv envs c = c { cCommand = "env" ++ (concat $ map (\(n, v) -> ' ' : (n ++ "=" ++ v)) envs) ++ " " ++ (cCommand c) }
88 91