From aa7a38f586583232306e41d540705246836613a6 Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Mon, 12 Aug 2024 11:55:06 +0100 Subject: [PATCH] ;doc: update stack doc urls --- Shake.hs | 2 +- bin/README.md | 13 ++----------- bin/gsheet-csv.hs | 2 +- 3 files changed, 4 insertions(+), 13 deletions(-) diff --git a/Shake.hs b/Shake.hs index d3a1af6a9..51bf0e806 100755 --- a/Shake.hs +++ b/Shake.hs @@ -22,7 +22,7 @@ Also uses tools like: - pandoc, groff, m4, makeinfo, sed, mv, cat, rm Some things that may be useful when working on this: -- https://docs.haskellstack.org/en/stable/GUIDE/#script-interpreter +- https://docs.haskellstack.org/en/stable/topics/scripts - watch Shake.hs for compile errors: make ghcid-shake - load Shake.hs in GHCI: make ghci-shake - rebuild things when files change with entr (file watcher), eg: diff --git a/bin/README.md b/bin/README.md index c34ba9cdd..55a94a0f6 100644 --- a/bin/README.md +++ b/bin/README.md @@ -338,7 +338,7 @@ is a custom compound report done in shell. See also hledger-report1.hs. ## hledger haskell scripts These scripts are written in Haskell and use hledger's haskell API (by importing the `hledger` or `hledger-lib` haskell libraries). -They are often [stack scripts]. +They are often [stack scripts](https://docs.haskellstack.org/en/stable/topics/scripts). They can do anything hledger's builtin commands can do, and are usually more robust than command line scripts. Some builtin commands were first developed as standalone haskell scripts. @@ -471,7 +471,7 @@ These are some official and third-party add-ons you can install as compiled prog To use these bin scripts you must ensure they are in your $PATH and runnable: -- Shell scripts: you may need [bash], or to adapt the scripts for your shell. +- Shell scripts: you may need [bash](https://www.gnu.org/software/bash), or to adapt the scripts for your shell. - Python scripts: you'll need python 3 and pip. - Haskell scripts: you'll need stack (). Or if you know how, you can make them cabal scripts, or install their dependencies manually and use runghc/ghc. @@ -505,17 +505,8 @@ $ pip install -U hledger-lots # Check that hledger's command list now includes the bin scripts. # Eg "check-fancyassertions" and "swap-dates" should be listed: $ hledger - - ``` -[bash]: https://www.gnu.org/software/bash -[stack]: https://haskellstack.org -[stack]: https://www.fpcomplete.com/haskell/get-started -[stack scripts]: https://docs.haskellstack.org/en/stable/GUIDE/#script-interpreter -[add-on commands]: https://hledger.org/dev/hledger.html#add-on-commands -[cabal]: https://www.haskell.org/cabal - ### Create a new script To create a new hledger-integrated script, copy hledger-script-example.hs. diff --git a/bin/gsheet-csv.hs b/bin/gsheet-csv.hs index 73ec3597f..822b6bc1e 100755 --- a/bin/gsheet-csv.hs +++ b/bin/gsheet-csv.hs @@ -96,6 +96,6 @@ exec ghcid - watch for compile errors 4. Declare which package each import is from, keep synced with --package; might as well be clear -5. Doc: https://docs.haskellstack.org/en/stable/GUIDE/#script-interpreter +5. Doc: https://docs.haskellstack.org/en/stable/topics/scripts -}