plutus icon indicating copy to clipboard operation
plutus copied to clipboard

A way to turn off indentation in the pretty-printer

Open effectfully opened this issue 1 year ago • 0 comments

@kwxm asks for a feature:

It might be useful to be able to turn off the indentation completely. I find that largish textual programs quickly become too large and too wide to read when I prettyprint them, so I end up using sed to transform the output. For example, the uniswap-3 script is 12721 bytes of flat, but when I convert it to textual form I get 24029 lines of output, the longest of them being 732 characters wide. There's a total of 10,221,880 characters, but if I delete all of the leading spaces that goes down to 105,491, which is a bit more manageable.

This should perhaps be just an additional flag in the pretty-printing config and a carefully placed group calls. Although we might have hardlines in the pretty-printing code.

effectfully avatar Apr 22 '24 15:04 effectfully