Skip to content

Commit

Permalink
Use installPath in warning message which is already in scope.
Browse files Browse the repository at this point in the history
  • Loading branch information
m-renaud committed Mar 30, 2020
1 parent 69f6f9d commit 71a6fc9
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions cabal-install/Distribution/Client/CmdInstall.hs
Original file line number Diff line number Diff line change
Expand Up @@ -658,13 +658,12 @@ installExes verbosity baseCtx buildCtx platform compiler

mkFinalExeName :: UnqualComponentName -> FilePath
mkFinalExeName exe = prefix <> unUnqualComponentName exe <> suffix <.> exeExtension platform
installdirUnknown path =
installdirUnknown =
"installdir is not defined. Set it in your cabal config file "
++ "or use --installdir=<path>. Using default installdir: " ++ show path
++ "or use --installdir=<path>. Using default installdir: " ++ show installPath

installdir <- fromFlagOrDefault
(warn verbosity (installdirUnknown installPath)
>> pure installPath) $
(warn verbosity installdirUnknown >> pure installPath) $
pure <$> cinstInstalldir clientInstallFlags
createDirectoryIfMissingVerbose verbosity False installdir
warnIfNoExes verbosity buildCtx
Expand Down

0 comments on commit 71a6fc9

Please sign in to comment.