Commit d9b40dc8 authored by Mikhail Glushenkov's avatar Mikhail Glushenkov
Browse files

Print a notice when 'install -j' is used inside a sandbox.

With 'install -j' it can be a bit hard to tell where the packages are
installed. This will be reworked once we get a unified dynamic UI for 'install'.
parent b27dd6c2
......@@ -70,7 +70,8 @@ import Distribution.Client.Config
import Distribution.Client.Sandbox.Timestamp
( withUpdateTimestamps )
import Distribution.Client.Sandbox.Types
( SandboxPackageInfo(..), UseSandbox(..), isUseSandbox )
( SandboxPackageInfo(..), UseSandbox(..), isUseSandbox
, whenUsingSandbox )
import Distribution.Client.Tar (extractTarGzFile)
import Distribution.Client.Types as Source
import Distribution.Client.BuildReports.Types
......@@ -847,6 +848,12 @@ performInstallations verbosity
globalFlags, configFlags, configExFlags, installFlags, haddockFlags)
installedPkgIndex installPlan = do
-- With 'install -j' it can be a bit hard to tell whether a sandbox is used.
whenUsingSandbox useSandbox $ \sandboxDir ->
when parallelBuild $
notice verbosity $ "Notice: installing into a sandbox located at "
++ sandboxDir
jobControl <- if parallelBuild then newParallelJobControl
else newSerialJobControl
buildLimit <- newJobLimit numJobs
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