mirror of
https://github.com/haskell/haskell-ide-engine.git
synced 2024-09-11 11:05:30 +03:00
Update HIE to use current master of hie-bios
This commit is contained in:
parent
7eb37dfb18
commit
2e368795d8
@ -73,7 +73,10 @@ run opts = do
|
||||
logm $ "Operating system:" ++ os
|
||||
|
||||
-- Get the cabal directory from the cradle
|
||||
cr <- findCradle (d </> "File.hs")
|
||||
conf <- findCradle (d </> "File.hs")
|
||||
cr <- case conf of
|
||||
Just yaml -> loadCradle yaml
|
||||
Nothing -> loadImplicitCradle (d </> "File.hs")
|
||||
let dir = cradleRootDir cr
|
||||
logm $ "Cradle directory:" ++ dir
|
||||
setCurrentDirectory dir
|
||||
|
@ -47,7 +47,9 @@ import Haskell.Ide.Engine.GhcUtils
|
||||
import Outputable hiding ((<>))
|
||||
-- This function should be defined in HIE probably, nothing in particular
|
||||
-- to do with BIOS
|
||||
import qualified HIE.Bios.GHCApi as BIOS (withDynFlags, CradleError,setDeferTypeErrors)
|
||||
import qualified HIE.Bios.Ghc.Api as BIOS (withDynFlags, setDeferTypeErrors)
|
||||
import qualified HIE.Bios.Ghc.Load as BIOS
|
||||
import qualified HIE.Bios.Flags as BIOS (CradleError)
|
||||
import qualified HIE.Bios as BIOS
|
||||
import Debug.Trace
|
||||
|
||||
|
@ -43,6 +43,7 @@ import qualified HscMain as GHC
|
||||
import qualified Data.Trie.Convenience as T
|
||||
import qualified Data.Trie as T
|
||||
import qualified HIE.Bios as BIOS
|
||||
import qualified HIE.Bios.Ghc.Api as BIOS
|
||||
import qualified Data.ByteString.Char8 as B
|
||||
|
||||
import Haskell.Ide.Engine.ArtifactMap
|
||||
@ -86,7 +87,10 @@ loadCradle iniDynFlags (NewCradle fp) = do
|
||||
maybe (return ()) cacheCradle =<< (currentCradle <$> getModuleCache)
|
||||
|
||||
-- Now load the new cradle
|
||||
crdl <- liftIO $ BIOS.findCradle fp
|
||||
crdlPath <- liftIO $ BIOS.findCradle fp
|
||||
crdl <- liftIO $ case crdlPath of
|
||||
Just yaml -> BIOS.loadCradle yaml
|
||||
Nothing -> BIOS.loadImplicitCradle fp
|
||||
traceShowM crdl
|
||||
liftIO (GHC.newHscEnv iniDynFlags) >>= GHC.setSession
|
||||
liftIO $ setCurrentDirectory (BIOS.cradleRootDir crdl)
|
||||
|
@ -123,6 +123,7 @@ import Data.Typeable ( TypeRep
|
||||
import System.Directory
|
||||
import GhcMonad
|
||||
import qualified HIE.Bios as BIOS
|
||||
import qualified HIE.Bios.Ghc.Api as BIOS
|
||||
import GHC.Generics
|
||||
import GHC ( HscEnv, GhcT )
|
||||
import Exception
|
||||
|
@ -27,7 +27,7 @@ import Haskell.Ide.Engine.ArtifactMap
|
||||
import qualified Language.Haskell.LSP.Types as LSP
|
||||
import qualified Language.Haskell.LSP.Types.Lens as LSP
|
||||
import Language.Haskell.Refact.API (hsNamessRdr)
|
||||
import HIE.Bios.Doc
|
||||
import HIE.Bios.Ghc.Doc
|
||||
|
||||
import GHC
|
||||
import HscTypes
|
||||
|
@ -34,7 +34,11 @@ extra-deps:
|
||||
- temporary-1.2.1.1
|
||||
# To make build work in windows 7
|
||||
- unix-time-0.4.7
|
||||
- yaml-0.8.32
|
||||
- dhall-1.20.1@sha256:3377090039ba3560b50515799affc57d74d2d3e57d3f8699bb2a9fc428fa4918,23401
|
||||
- extra-1.6.18@sha256:5f1fff126f0ae47b701fff5aa8462dc63cb44465d5a724b0afd20a3d731903af
|
||||
- unix-compat-0.5.2@sha256:16763f1fae4a25abf61ac6195eb530ce838474bd04d86c7d353340aee8716bbb
|
||||
- yaml-0.11.1.2@sha256:cbc4ddb233c564967aad27ee47c1cd8fd6a06b9183353e76fe66c9be7c9dfd76
|
||||
- unordered-containers-0.2.10.0@sha256:5e9b095a9283d9e2f064fec73a81a6b6ea0b7fda3f219a8175785d2d2a3de204
|
||||
|
||||
# allow-newer: true
|
||||
|
||||
|
@ -30,7 +30,10 @@ extra-deps:
|
||||
- rope-utf16-splay-0.3.1.0
|
||||
- syz-0.2.0.0
|
||||
- temporary-1.2.1.1
|
||||
- yaml-0.8.32
|
||||
- dhall-1.20.1@sha256:3377090039ba3560b50515799affc57d74d2d3e57d3f8699bb2a9fc428fa4918,23401
|
||||
- extra-1.6.18@sha256:5f1fff126f0ae47b701fff5aa8462dc63cb44465d5a724b0afd20a3d731903af
|
||||
- unix-compat-0.5.2@sha256:16763f1fae4a25abf61ac6195eb530ce838474bd04d86c7d353340aee8716bbb
|
||||
- yaml-0.11.1.2@sha256:cbc4ddb233c564967aad27ee47c1cd8fd6a06b9183353e76fe66c9be7c9dfd76
|
||||
|
||||
flags:
|
||||
haskell-ide-engine:
|
||||
|
@ -28,9 +28,10 @@ extra-deps:
|
||||
- monad-dijkstra-0.1.1.2@rev:1
|
||||
- syz-0.2.0.0
|
||||
- temporary-1.2.1.1
|
||||
- yaml-0.8.32
|
||||
- dhall-1.20.1@sha256:3377090039ba3560b50515799affc57d74d2d3e57d3f8699bb2a9fc428fa4918,23401
|
||||
|
||||
- extra-1.6.18@sha256:5f1fff126f0ae47b701fff5aa8462dc63cb44465d5a724b0afd20a3d731903af
|
||||
- unix-compat-0.5.2@sha256:16763f1fae4a25abf61ac6195eb530ce838474bd04d86c7d353340aee8716bbb
|
||||
- yaml-0.11.1.2@sha256:cbc4ddb233c564967aad27ee47c1cd8fd6a06b9183353e76fe66c9be7c9dfd76
|
||||
|
||||
# allow-newer: true
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user