aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/apps/ListPath.hs
diff options
context:
space:
mode:
Diffstat (limited to 'apps/ListPath.hs')
-rw-r--r--apps/ListPath.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/ListPath.hs b/apps/ListPath.hs
index 469fbba..e0cbefe 100644
--- a/apps/ListPath.hs
+++ b/apps/ListPath.hs
@@ -24,7 +24,7 @@ options = Options <$> optNameDesc
where
optNameDesc = strOption $
long "name" <> short 'n' <> metavar "NAME" <> value "PATH" <>
- help "Specify variable name ('PATH' by default)"
+ help "Variable name ('PATH' by default)"
main :: IO ()
main = execParser parser >>= listPath
@@ -40,6 +40,7 @@ listPath options = do
where
varName = optName options
getEnv = liftM (fromMaybe "") . lookupEnv
+
printPath p = do
exists <- doesDirectoryExist p
putStrLn $ (if exists then "+" else "-") ++ " " ++ p