From 1ebd244abbc3222f9a1cf5d4d8d73a7ea4b5db84 Mon Sep 17 00:00:00 2001 From: Jonathan Dowland Date: Thu, 31 Aug 2023 14:27:00 +0100 Subject: [PATCH] ;dev: Add a ghc-tags.yaml file Provide a ghc-tags.yaml file to make use of ghc-tags with Hledger easy. ghc-tags is a standalone tool to replace the formerly-built-in ":ctags" feature (and I presume ":etags") in GHCi. These walked over the source and produced a TAGS file (in vim-compatible ctags or Emacs-compatible etags format) that allows the relevant editors to quickly navigate around function definitions. ghc-tags trips over some of the CPP used in Hledger. The solution is to provide ghc-tags with explicit CPP defines via a YAML file. However, if a YAML file is provided, one also must specify the source paths, as the tool XORs config file | paths-on-command-line. See for more information. Signed-off-by: Jonathan Dowland --- ghc-tags.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 ghc-tags.yaml diff --git a/ghc-tags.yaml b/ghc-tags.yaml new file mode 100644 index 000000000..04d126a07 --- /dev/null +++ b/ghc-tags.yaml @@ -0,0 +1,8 @@ +source_paths: +- hledger +- hledger-lib +- hledger-ui +- hledger-web +cpp_options: +- -DMIN_VERSION_megaparsec(x,y,z)=1 +- -DMIN_VERSION_aeson(x,y,z)=1