summaryrefslogtreecommitdiff
path: root/Biz/Bild.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Biz/Bild.hs')
-rw-r--r--Biz/Bild.hs39
1 files changed, 0 insertions, 39 deletions
diff --git a/Biz/Bild.hs b/Biz/Bild.hs
index 845daf1..ce97807 100644
--- a/Biz/Bild.hs
+++ b/Biz/Bild.hs
@@ -44,8 +44,6 @@
--
-- * flags modify the way to interact with the build, some ideas:
--
--- * -s = jump into a shell and/or repl
---
-- * -p = turn on profiling
--
-- * -t = limit build by type (file extension)
@@ -68,16 +66,6 @@
-- This will build the file at ./A/B.hs, which translates to something like
-- `ghc --make A.B`.
--
--- > bild -s <target>
---
--- Starts a repl/shell for target.
---
--- - if target.hs, load ghci
--- - if target.scm, load scheme repl
--- - if target.clj, load a clojure repl
--- - if target.nix, load nix-shell
--- - and so on.
---
-- > bild -p <target>
--
-- build target with profiling (if available)
@@ -187,8 +175,6 @@ move args =
|> Map.elems
|> putJSON
>> pure [Exit.ExitSuccess]
- | args `Cli.has` Cli.longOption "repl" =
- traverse (repl isLoud) (Map.elems analyses)
| otherwise = do
root <- Env.getEnv "BIZ_ROOT"
createHier root
@@ -468,31 +454,6 @@ test loud Target {..} = case compiler of
>> Log.br
>> pure Exit.ExitSuccess
-repl :: Bool -> Target -> IO Exit.ExitCode
-repl _ Target {..} = do
- root <- Env.getEnv "BIZ_ROOT"
- case compiler of
- c
- | c `elem` [GhcExe, GhcLib] ->
- -- this is a complicated set of string joins which basically means to
- -- create a command like this:
- -- nix-shell -E "with import Biz/Bild.nix {}; mkGhcPackageSet (h: [h.pkg])"
- [ "--expr",
- "with import " <> root <> "/Biz/Bild.nix {};"
- <> "mkGhcPackageSet (h: ["
- <> joinWith " " ["h." <> d | d <- Set.toList langdeps]
- <> "])",
- -- Set.toList sysdeps,
- "--command",
- "ghci -i$BIZ_ROOT -ghci-script $BIZ_ROOT/.ghci " <> path
- ]
- |> Process.callProcess "nix-shell"
- >> Exit.exitSuccess
- _ ->
- Log.fail ["repl", nschunk namespace, "not implemented"]
- >> Log.br
- >> Exit.exitFailure
-
build :: Bool -> Bool -> Target -> IO Exit.ExitCode
build andTest loud target@Target {..} = do
root <- Env.getEnv "BIZ_ROOT"