terraform/repl
Alisdair McDiarmid 4e7607deb5 repl: Display multi-line strings as heredocs
The console and output formatter previously displayed multi-line strings
with escaped newlines, e.g. `"hello\nworld\n"`. While this is a valid
way to write the HCL string, it is not as common or as readable as using
the heredoc syntax, e.g.

<<EOF
hello
world
EOF

This commit adds heredoc detection and display to this formatter,
including support for indented heredocs for nested multi-line strings.
This change affects the apply, console, and output sub-commands.
2020-11-26 11:42:31 -05:00
..
testdata/config-fixture repl: Fix tests 2018-10-16 19:14:11 -07:00
format.go repl: Display multi-line strings as heredocs 2020-11-26 11:42:31 -05:00
format_test.go repl: Display multi-line strings as heredocs 2020-11-26 11:42:31 -05:00
repl.go repl: package for TF REPL 2016-11-13 23:17:03 -08:00
session.go repl: Improved value renderer for console outputs 2020-09-14 09:47:12 -04:00
session_test.go use a single log writer 2020-10-19 14:29:54 -04:00