From 7f0d38fe9000751058745e34e18b2484abe1d636 Mon Sep 17 00:00:00 2001 From: Mike Farah Date: Fri, 22 Jul 2022 08:51:28 +1000 Subject: [PATCH] adedd string blocks link in tips and tricks --- usage/tips-and-tricks.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/usage/tips-and-tricks.md b/usage/tips-and-tricks.md index d6a3e5b8..ea94be99 100644 --- a/usage/tips-and-tricks.md +++ b/usage/tips-and-tricks.md @@ -55,6 +55,11 @@ The `strenv` operator is a great way to handle special characters in strings: VAL='.a |!@ == "string2"' yq '.a = strenv(VAL)' example.yaml ``` +## String blocks and newline issues +There are a couple of tricks to getting the right string representation, take a look here for more details: + +https://mikefarah.gitbook.io/yq/operators/string-operators#string-blocks-bash-and-newlines + ## Quotes in Windows Powershell Powershell has its [own](https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about\_quoting\_rules?view=powershell-7.1) way of handling quotes: