mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-08-08 16:01:53 -07:00
ShellPrompt: remove harcoded path when calling bash
This commit is contained in:
@@ -81,7 +81,7 @@ unsafePrompt c config = mkXPrompt Shell config (getShellCompl [c]) run
|
|||||||
getShellCompl :: [String] -> String -> IO [String]
|
getShellCompl :: [String] -> String -> IO [String]
|
||||||
getShellCompl cmds s | s == "" || last s == ' ' = return []
|
getShellCompl cmds s | s == "" || last s == ' ' = return []
|
||||||
| otherwise = do
|
| otherwise = do
|
||||||
f <- fmap lines $ runProcessWithInput "/bin/bash" [] ("compgen -A file " ++ s ++ "\n")
|
f <- fmap lines $ runProcessWithInput "bash" [] ("compgen -A file " ++ s ++ "\n")
|
||||||
return . map escape . uniqSort $ f ++ commandCompletionFunction cmds s
|
return . map escape . uniqSort $ f ++ commandCompletionFunction cmds s
|
||||||
|
|
||||||
commandCompletionFunction :: [String] -> String -> [String]
|
commandCompletionFunction :: [String] -> String -> [String]
|
||||||
|
Reference in New Issue
Block a user