ndmitchell / hoogle

Haskell API search engine
http://hoogle.haskell.org/
Other
738 stars 134 forks source link

Allow indexing multiple local packages #193

Closed iliastsi closed 7 years ago

iliastsi commented 7 years ago

Patch generate command to accept the `--local' flag more than once, hence enabling Hoogle to generate docs for more than one packages at same database.

Note that with this patch, passing --local <dir1> --local --local <dir2> is allowed, and will fail with

hoogle: : getDirectoryContents: does not exist (No such file or directory)

This is not optimal, but it was done in Debian in order to keep backward compatibility (i.e., support both --local and --local <dir> as before). We could probably create a new flag, namely --ghc-pkg and drop the empty --local one. What do you think?

Closes #192: Allow indexing multiple local packages

ndmitchell commented 7 years ago

Thanks, all merged and a few refinements afterwards. I think having a separate --ghc-pkg flag is a good idea, since they are quite different concepts. I'd welcome a patch to do that, or I'll tidy it up sometime later when refactoring these pieces - certainly not in any rush.