I am available for hire as a software freelancer – telecommuting, Europe, the Americas, Middle East, …
My blog is *my* blog. You have to be either rather nice for your comments to get through here - or *rather* beautiful.
Friday, July 9, 2010
best practices in shell script programming
You do know the result of this:
a=A; echo $a
But are you just as sure here?
a=A; b=B; echo $a.$b
That depends on the shell, you are using. So I suggest you better write it this way:
a=A; b=B; echo ${a}.${b}
Enclosing variable names in curly braces is quite often a good idea.
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.