{"id":13647074,"url":"https://github.com/bgamari/hoogle-index","last_synced_at":"2025-03-22T13:31:58.969Z","repository":{"id":21418161,"uuid":"24736237","full_name":"bgamari/hoogle-index","owner":"bgamari","description":"Easily generate Hoogle indices for installed packages","archived":false,"fork":false,"pushed_at":"2016-04-13T14:22:41.000Z","size":34,"stargazers_count":25,"open_issues_count":3,"forks_count":2,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-03-18T11:48:14.927Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Haskell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bgamari.png","metadata":{"files":{"readme":"README.mkd","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-10-02T20:54:35.000Z","updated_at":"2020-04-21T08:02:19.000Z","dependencies_parsed_at":"2022-08-21T08:41:09.946Z","dependency_job_id":null,"html_url":"https://github.com/bgamari/hoogle-index","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bgamari%2Fhoogle-index","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bgamari%2Fhoogle-index/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bgamari%2Fhoogle-index/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bgamari%2Fhoogle-index/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bgamari","download_url":"https://codeload.github.com/bgamari/hoogle-index/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244962937,"owners_count":20539247,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-02T01:03:19.807Z","updated_at":"2025-03-22T13:31:58.728Z","avatar_url":"https://github.com/bgamari.png","language":"Haskell","funding_links":[],"categories":["Haskell"],"sub_categories":[],"readme":"# hoogle-index — Painless local Haddock indexing\n\n`hoogle-index` is a small utility for generating indicies for local\nHoogle installations.\n\n```bash\n$ cabal install hoogle hoogle-index\n$ hoogle-index -i -l   # this will take a couple of minutes\n$ hoogle server -l -p 9000\n$ firefox http://localhost:9000/\n```\n\nYour Hoogle index now covers all of the packages locally installed.\n\n## What it does\n\nFirst the utility identifies what packages have been installed. We\ntraverse these packages in topological order to ensure that Hoogle can\nresolve as many references as possible.\n\nFor each package, the utility first checks the package's documentation\nfor an existing textbase (a textual description of a package's interface\ngenerated by `haddock`). While these are provided with some packages\n(e.g. those installed with GHC), in most cases we'll need to generate\none. To do this we unpack the package source, configure it, and invoke\nHaddock. To avoid needing regenerate this file in future runs we also\ninstall the resulting textbase in the appropriate spot in `~/.cabal`.\n\nWith a textbase in hand we can convert this to a Hoogle database.\nAfter traversing all installed packages these individual databases are\nmerged.\n\n## Sandbox support\n\n`hoogle-index` has basic support for cabal sandboxes. Simply run `hoogle-index`\nwithin the root directory of your sandbox and invoke `hoogle` using\n`hoogle-index`'s `hoogle` subcommand. For instance,\n\n```bash\n$ mkdir test\n$ cabal sandbox init\n$ cabal install acme-missiles\n$ hoogle-index -l\n$ hoogle-index hoogle launchMissiles\nAcme.Missiles launchMissiles :: IO ()\nAcme.Missiles.STM launchMissilesSTM :: STM ()\n```\n\n## Caveats\n\nAt the moment `hoogle-index` is an unholy combination of using the `Cabal`\nlibrary directly and invoking the `cabal-install` binary. This means that\nthings will break if any of the following conditions do not hold,\n\n * `cabal-install` is compiled against the same `Cabal` version as `hoogle-index`\n   (`cabal -V` will report the version that `cabal-install` is built against)\n * `haddock` is compiled against the GHC version currently in use\n\nMoreover, some older `hoogle` releases will fail with some Haskell extensions. \nThis has been [fixed upstream](https://github.com/ndmitchell/hoogle/pull/85).\n\n## More resources\n\n * [Hoogle](http://www.haskell.org/haskellwiki/Hoogle)\n * [Database generation](http://neilmitchell.blogspot.com/2008/08/hoogle-database-generation.html)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbgamari%2Fhoogle-index","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbgamari%2Fhoogle-index","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbgamari%2Fhoogle-index/lists"}