I've recently started using Haskell Turtle library to replace some of my shell scripts.
Is there a way to somehow enable echoing of built in Turtle commands (like cd) ala set -x
in bash scripts? I find it quite problematic to debug Turtle scripts in cases where many commands are executed and one of them fails with exception (like cp
command with Exception:openBinaryFile: does not exist
). Alternatively do you have some recommendation how to quickly isolate problems like these, so that I don't have to intersperse puStrLn/echo
commands throughout my script?