Bash Built-In Variables: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 10: | Line 10: | ||
:'''Note''' you must set IFS back to " " after setting it to something else, so the basic shell function work as expected. This is done with IFS=" ".<br> | :'''Note''' you must set IFS back to " " after setting it to something else, so the basic shell function work as expected. This is done with IFS=" ".<br> | ||
</blockquote> | </blockquote> | ||
===IFS and for=== | |||
<tt>for</tt> honors the value of IFS (default the space). If you set IFS to something else, for will use that as field separator while iterating over the list. | |||
Also see: | Also see: |
Revision as of 23:38, 29 February 2016
Internal
Standard Environment Variables
IFS
- Note you must set IFS back to " " after setting it to something else, so the basic shell function work as expected. This is done with IFS=" ".
IFS and for
for honors the value of IFS (default the space). If you set IFS to something else, for will use that as field separator while iterating over the list.
Also see: