Show HN: Eyeball: Detect and understand changes in a program's output
1–4 of 4 posts
Re: Show HN: Eyeball: Detect and understand changes in a program's output
#2Have you tested your script with files like " this has spaces .out"? I think you are missing some quotes around your variable expansions.
Re: Show HN: Eyeball: Detect and understand changes in a program's output
#3Have you tested your script with files like " this has spaces .out"? I think you are missing some quotes around your variable expansions.
Wow, eagle eyes. Thank you. Any tips on how to deal with quotes around variable expansions in general? Should I quote each usage of a variable or does it depend on context?
Re: Show HN: Eyeball: Detect and understand changes in a program's output
#4Have you tested your script with files like " this has spaces .out"? I think you are missing some quotes around your variable expansions.
Wow, eagle eyes. Thank you. Any tips on how to deal with quotes around variable expansions in general? Should I quote each usage of a variable or does it depend on context?
Quoting each usage of a variable is almost always correct.
The only context where it isn't correct is when you need word-splitting to occur, which is almost never.
Even "$@" is special-cased to do the right thing and quote each individual parameter, instead of the whole list.