Tab Indented Standard Input Redirect in Bash
I managed to forget how to redirect standard input (when you want to feed a bunch of lines to a program) in a bash script while still indenting and had to go digging around for it. So I figured I’d make a note here so I don’t forget again and for anyone else in the same boat. It’s just <<-
instead of <<
. For example if you want to keep indentation within a loop:
<<-
doesn’t work with spaces for indentation (although I’m a tab man myself).