My Profile Photo
name := "Graham Beer"

`Cloud Engineer with his head in the AWS clouds, authored chapters in the PowerShell Conference Book 1 & 2 and currently learning and enjoying Go


PowerShell Conf Book Planet PowerShell Top 50 PowerShell

The PowerShell Here-String – Preserve text formatting

Like many other high-level languages, PowerShell gives us the ability to preserve line breaks, tabs, whitespace, and other text formatting with the here-string. I’m going to be looking how you create and use a here-string in PowerShell.

Many other languages use the here-string, and it is not PowerShell specific. Other languages call the here-string by a different name: here-document, here-text, heredoc, and hereis to name a few. Unix shells like bash and zsh first used here-documents. Languages such as PHP, Python, and Ruby have also adopted their own “here-document.”

4sysops article continues here…