diff options
author | gwern0 <gwern0@gmail.com> | 2011-11-28 00:15:07 +0100 |
---|---|---|
committer | gwern0 <gwern0@gmail.com> | 2011-11-28 00:15:07 +0100 |
commit | bfad1779b3389f8e79e2097298c419ec63b6d43d (patch) | |
tree | 8ed767152189b6da1b0545b6546409e52a242141 | |
parent | 0be3b28dc39e933975389d755b54577d5fac9baf (diff) | |
download | XMonadContrib-bfad1779b3389f8e79e2097298c419ec63b6d43d.tar.gz XMonadContrib-bfad1779b3389f8e79e2097298c419ec63b6d43d.tar.xz XMonadContrib-bfad1779b3389f8e79e2097298c419ec63b6d43d.zip |
XMonad.Prompt.Shell: improve 'env' documentation to cover goodgrue's problem
Ignore-this: 7b652a280960cbdf99c236496ca091b0
darcs-hash:20111127231507-f7719-d135757d9c584e50d0cd4112d1a4d2fe87841f91.gz
-rw-r--r-- | XMonad/Prompt/Shell.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/XMonad/Prompt/Shell.hs b/XMonad/Prompt/Shell.hs index 8dd151c..49b12f7 100644 --- a/XMonad/Prompt/Shell.hs +++ b/XMonad/Prompt/Shell.hs @@ -130,7 +130,9 @@ escape (x:xs) isSpecialChar :: Char -> Bool isSpecialChar = flip elem " &\\@\"'#?$*()[]{};" --- | Ask the shell environment for +-- | Ask the shell environment for the value of a variable in XMonad's environment, with a default value. +-- In order to /set/ an environment variable (eg. combine with a prompt so you can modify @$HTTP_PROXY@ dynamically), +-- you need to use 'System.Posix.putEnv'. env :: String -> String -> IO String env variable fallthrough = getEnv variable `catch` econst fallthrough |