From 21075f62501ecf18d7e56cbe2212ba02bea141db Mon Sep 17 00:00:00 2001 From: Yuchen Pei Date: Mon, 5 Sep 2022 15:44:41 +1000 Subject: Adding docs about the emacs binding. --- README.org | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/README.org b/README.org index 4ca30be..992f55d 100644 --- a/README.org +++ b/README.org @@ -3,6 +3,8 @@ hcel is a fork of [[https://github.com/alexwl/haskell-code-explorer][Haskell Code Explorer]], it works with GHC-9.2.2 with Cabal-3.6.2.0, and possibly other adjacent versions. +It also comes with an emacs binding. + * Install #+begin_src sh @@ -52,6 +54,28 @@ testsuites and benchmarks, in the .cabal file, therefore you'll need to build them all before indexing, otherwise the indexer will complain about missing files. +* Emacs binding +You may find an emacs client under the ~lisp~ directory. It covers + almost all features in the js client, and more: + +- Jump to definition (using xref) +- Find references (based on compilation mode) +- Search identifiers in a package or globally (based on compilation mode) +- Highlight the identifier at point +- Browse packages, modules and identifiers in an outline mode +- Eldoc integration, showing type and documentation of the identifier + at point, or the selected expression. +- Syntax highlight (requires haskell-mode) + +To use, start a server, and set the endpoint: + +#+begin_src elisp +(require 'hc) +(setq hcel-endpoint "localhost:8080") +#+end_src + +To start, run command ~hcel~ to enter the outline mode. + * Contact and Copyright The original haskell-code-explorer is written by Alexey Kiryushin -- cgit v1.2.3