diff options
Diffstat (limited to 'Biz')
-rw-r--r-- | Biz/Bild.hs | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/Biz/Bild.hs b/Biz/Bild.hs index cf471fe..7bfa788 100644 --- a/Biz/Bild.hs +++ b/Biz/Bild.hs @@ -292,14 +292,14 @@ dev_getTarget = do Just t -> t data Builder - = -- | Local <user> - Local Text + = -- | Local <user> <host> + Local Text Text | -- | Remote <user> <host> Remote Text Text deriving (Show, Generic) instance Aeson.ToJSON Builder where - toJSON (Local u) = Aeson.String u + toJSON (Local u host) = Aeson.String <| u <> "@" <> host toJSON (Remote u host) = Aeson.String <| u <> "@" <> host class ToNixFlag a where @@ -307,7 +307,7 @@ class ToNixFlag a where instance ToNixFlag Builder where toNixFlag = \case - Local _ -> "" + Local _ _ -> mempty Remote u h -> Text.unpack <| Text.concat ["ssh://", u, "@", h, "?ssh-key=/home/", u, "/.ssh/id_rsa"] -- | We can't build everything yet... @@ -435,7 +435,7 @@ analyze hmap ns = case Map.lookup ns hmap of sysdeps = psys, wrapper = Nothing, compiler = Gcc, - builder = Local user, + builder = Local user host, out = pout, packageSet = "", -- none, or maybe I should make cPackages? compilerFlags = @@ -461,7 +461,7 @@ analyze hmap ns = case Map.lookup ns hmap of |> \out -> detectHaskellImports hmap contentLines +> \(langdeps, srcs) -> Target - { builder = Local user, + { builder = Local user host, wrapper = Nothing, compiler = Ghc, packageSet = "ghcWith", @@ -510,13 +510,13 @@ analyze hmap ns = case Map.lookup ns hmap of "--eval", "(sb-ext:save-lisp-and-die #p\"" <> (root </> outToPath out) <> "\" :toplevel #'main :executable t)" ], - builder = Local <| user, + builder = Local user host, outPath = outToPath out, srcs = Set.singleton absPath, .. } Namespace.Nix -> - (host == "lithium") ?: (Local user, Remote user "dev.simatime.com") |> \builder -> + (host == "lithium") ?: (Local user "lithium", Remote user "dev.simatime.com") |> \builder -> Target { langdeps = Set.empty, wrapper = Nothing, @@ -553,7 +553,7 @@ analyze hmap ns = case Map.lookup ns hmap of absPath ] |> map Text.pack, - builder = Local user, + builder = Local user host, outPath = outToPath pout, out = pout, srcs = Set.singleton absPath, @@ -585,7 +585,7 @@ analyze hmap ns = case Map.lookup ns hmap of sysdeps = Set.empty, compiler = Rustc, compilerFlags = map Text.pack [absPath, "-o", root </> outToPath out], - builder = Local user, + builder = Local user host, outPath = outToPath out, srcs = Set.singleton absPath, .. @@ -728,8 +728,8 @@ build andTest loud analysis = -- | Format for logging toLog :: Builder -> Text -toLog (Local u) = u -toLog (Remote u h) = u <> "@" <> h +toLog (Local u h) = "local://" <> u <> "@" <> h +toLog (Remote u h) = "remote://" <> u <> "@" <> h data Proc = Proc { loud :: Bool, |