on master help sign in
Make ghcide on the command line use absolute file paths (#401)
f06cae0Neil Mitchell
exe/Main.hs+3−1
@@ -107,7 +107,9 @@ main = do
107 putStrLn "Report bugs at https://github.com/digital-asset/ghcide/issues"
107 putStrLn "Report bugs at https://github.com/digital-asset/ghcide/issues"
108
108
109 putStrLn $ "\nStep 1/6: Finding files to test in " ++ dir
109 putStrLn $ "\nStep 1/6: Finding files to test in " ++ dir
110− files <- nubOrd <$> expandFiles (argFiles ++ ["." | null argFiles])
110+ files <- expandFiles (argFiles ++ ["." | null argFiles])
111+ -- LSP works with absolute file paths, so try and behave similarly
112+ files <- nubOrd <$> mapM canonicalizePath files
111 putStrLn $ "Found " ++ show (length files) ++ " files"
113 putStrLn $ "Found " ++ show (length files) ++ " files"
112
114
113 putStrLn "\nStep 2/6: Looking for hie.yaml files that control setup"
115 putStrLn "\nStep 2/6: Looking for hie.yaml files that control setup"