Closed ExpHP closed 7 years ago
Do you have a shell alias for hoogle, which is doing something like hoogle --color
when expanded? If you type hoogle generate ...
then it gets treated as a command to generate - but if you do hoogle --flag generate
then it expands implicitly to hoogle search --flag generate
, and does a search for generate
.
You are spot on! I set one and completely forgot about it:
$ type hoogle
hoogle is aliased to `hoogle --color --count=10'
$ \hoogle generate
Starting generate
Downloading https://www.stackage.org/lts/cabal.config... 0.85s
[...]
So I take it this behavior is working as designed? Sorry then for the issue that basically amounted to tech support (but also, thanks for the help!)
No problem - it actually seems to be something a lot of people have done - you are far from the first.
I am running into a curious issue, where
hoogle generate
appears to be demanding the impossible!Acknowledged, the potential for PEBKAC here is high, as I find it hard to believe I'm the first to report this if this were a real issue affecting multiple users.
Things I tried
~/.hoogle
This directory does not exist, but creating it makes no difference.
rtfm || google fu
hoogle --help
. (hoogle generate --help
has the same output)hoogle data
subcommand as some sites mention (guess that's hoogle 4)Reinstalling all cabal packages
Since I got hoogle through cabal, I tried reinstalling all cabal packages. Due to PEBKAC potential, I am including the exact steps I performed (in particular, I installed other packages alongside hoogle):
Details on purge and reinstall
``` $ rm -rf ~/.ghc $ cabal update $ # NOTE: cabal is aliased to "cabal: --require-sandbox" $ cabal --no-require-sandbox install alex idris hoogle pointful threadscope hlint (~90 minutes later, it finishes with errors installing idris) $ cabal --no-require-sandbox install hoogle Resolving dependencies... All the requested packages are already installed: hoogle-5.0.9 Use --reinstall if you want to reinstall anyway. $ ls -l `which hoogle` (timestamp was about 20 minutes old; clearly created during the reinstall) $ hoogle generate Error, database does not exist (run 'hoogle generate' first) Filename: /home/lampam/.hoogle/default-haskell-5.0.9.hoo ```I may try again later with a more thorough purge and a more minimal reinstall.
Versions
(these versions are after the reinstall mentioned above)