[commit: Cabal] master: add message to 'package not found' error advising to run 'cabal update'. (#497) (9a9b519)
Ian Lynagh
igloo at earth.li
Fri Jun 24 02:03:50 CEST 2011
Repository : ssh://darcs.haskell.org//srv/darcs/packages/Cabal
On branch : master
http://hackage.haskell.org/trac/ghc/changeset/9a9b519c368ceb0ebd63b52efef4abc5f13f6301
>---------------------------------------------------------------
commit 9a9b519c368ceb0ebd63b52efef4abc5f13f6301
Author: Brent Yorgey <byorgey at cis.upenn.edu>
Date: Thu Jun 11 17:12:33 2009 +0000
add message to 'package not found' error advising to run 'cabal update'. (#497)
>---------------------------------------------------------------
cabal-install/Distribution/Client/IndexUtils.hs | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/cabal-install/Distribution/Client/IndexUtils.hs b/cabal-install/Distribution/Client/IndexUtils.hs
index bcc0651..1110e87 100644
--- a/cabal-install/Distribution/Client/IndexUtils.hs
+++ b/cabal-install/Distribution/Client/IndexUtils.hs
@@ -234,7 +234,8 @@ disambiguateDependencies index deps = do
(_, Left name)) <- zip deps names ]
ambigious -> die $ unlines
[ if null matches
- then "There is no package named " ++ display name
+ then "There is no package named " ++ display name ++ ". "
+ ++ "Perhaps you need to run 'cabal update' first?"
else "The package name " ++ display name ++ "is ambigious. "
++ "It could be: " ++ intercalate ", " (map display matches)
| (name, matches) <- ambigious ]
More information about the Cvs-libraries
mailing list