Commit b47bd516 authored by Moritz Angermann's avatar Moritz Angermann
Browse files

👍

parent 0fa71d10
......@@ -95,8 +95,10 @@ builderPath builder = do
putError $ "\nCannot find path to '" ++ (builderKey builder)
++ "' in configuration files."
windows <- windowsHost
let path' = if null path then "" else path -<.> exe in
(if windows then fixAbsolutePathOnWindows else lookupInPath) path'
case (path, windows) of
("", _) -> return path
(p, True) -> fixAbsolutePathOnWindows (p -<.> exe)
(p, False) -> lookupInPath (p -<.> exe)
getBuilderPath :: Builder -> ReaderT a Action FilePath
getBuilderPath = lift . builderPath
......
......@@ -46,7 +46,6 @@ lookupInPath c
| otherwise = do
envPaths <- splitOn ":" <$> getEnvWithDefault "" "PATH"
let candidates = map (-/- c) envPaths
liftIO $ mapM_ putStrLn candidates
-- this will crash if we do not find any valid candidate.
head <$> filterM doesFileExist candidates
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment