Penguin

Differences between version 8 and previous revision of HereStrings.

Other diffs: Previous Major Revision, Previous Author, or view the Annotated Edit History

Newer page: version 8 Last edited on Monday, December 11, 2006 1:57:45 am by BenStaz Revert
Older page: version 7 Last edited on Sunday, December 10, 2006 9:45:48 am by BenStaz Revert
@@ -14,4 +14,10 @@
  
 *echo $foo $bar $moo 
  
 and hopefully the value of the three variables will be displayed for you. 
+  
+!Read from a variable  
+Make sure the variable is surrounded by double quotes!  
+  
+*string="this:is:a:string"; IFS=: ; read foo bar moo cow <<< "$string"  
+*echo $foo $bar $moo $cow