<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Delimiters in Bash</title>
	<atom:link href="http://www.debianadmin.com/delimiters-in-bash.html/feed" rel="self" type="application/rss+xml" />
	<link>http://www.debianadmin.com/delimiters-in-bash.html</link>
	<description>Debian/Ubuntu Linux System Administration Tutorials,Howtos,Tips</description>
	<lastBuildDate>Thu, 19 Nov 2009 13:24:32 -0500</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: xleo</title>
		<link>http://www.debianadmin.com/delimiters-in-bash.html/comment-page-1#comment-3642</link>
		<dc:creator>xleo</dc:creator>
		<pubDate>Fri, 11 Sep 2009 23:09:15 +0000</pubDate>
		<guid isPermaLink="false">http://www.debianadmin.com/?p=855#comment-3642</guid>
		<description>Array version:

IFS=&quot;:&quot;; while read line; do array=($line); echo ${array[0]}; done &lt; /etc/passwd</description>
		<content:encoded><![CDATA[<p>Array version:</p>
<p>IFS=&#8221;:&#8221;; while read line; do array=($line); echo ${array[0]}; done &lt; /etc/passwd</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: garywk</title>
		<link>http://www.debianadmin.com/delimiters-in-bash.html/comment-page-1#comment-3617</link>
		<dc:creator>garywk</dc:creator>
		<pubDate>Tue, 01 Sep 2009 11:34:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.debianadmin.com/?p=855#comment-3617</guid>
		<description>I played around with your script for a while and got it to work after making a few modifications.   

#!/bin/bash



IFS=”:”

while read  username pass auid agid agroup ahome ashell 

do

echo $username

echo $pass

echo $auid

echo $agid

echo $agroup

echo $ahome

echo $ashell

echo “--------”

sleep 1

done &lt; /etc/passwd

exit 0</description>
		<content:encoded><![CDATA[<p>I played around with your script for a while and got it to work after making a few modifications.   </p>
<p>#!/bin/bash</p>
<p>IFS=”:”</p>
<p>while read  username pass auid agid agroup ahome ashell </p>
<p>do</p>
<p>echo $username</p>
<p>echo $pass</p>
<p>echo $auid</p>
<p>echo $agid</p>
<p>echo $agroup</p>
<p>echo $ahome</p>
<p>echo $ashell</p>
<p>echo “&#8212;&#8212;&#8211;”</p>
<p>sleep 1</p>
<p>done &lt; /etc/passwd</p>
<p>exit 0</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jeff Price</title>
		<link>http://www.debianadmin.com/delimiters-in-bash.html/comment-page-1#comment-3226</link>
		<dc:creator>Jeff Price</dc:creator>
		<pubDate>Wed, 17 Jun 2009 17:21:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.debianadmin.com/?p=855#comment-3226</guid>
		<description>The example was a dirty one, It may fail if the lines have comments such as #

try this in a terminal

IFS=&quot;:&quot;
read a b c d&lt;&lt;EOF
Hello:World:Apples:Oranges
EOF
echo $a
unset IFS</description>
		<content:encoded><![CDATA[<p>The example was a dirty one, It may fail if the lines have comments such as #</p>
<p>try this in a terminal</p>
<p>IFS=&#8221;:&#8221;<br />
read a b c d&lt;&lt;EOF<br />
Hello:World:Apples:Oranges<br />
EOF<br />
echo $a<br />
unset IFS</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Scott M</title>
		<link>http://www.debianadmin.com/delimiters-in-bash.html/comment-page-1#comment-3225</link>
		<dc:creator>Scott M</dc:creator>
		<pubDate>Wed, 17 Jun 2009 16:46:46 +0000</pubDate>
		<guid isPermaLink="false">http://www.debianadmin.com/?p=855#comment-3225</guid>
		<description>Hmm, not working for me.  Outputs just a bunch of blank lines separated by the &quot;--------&quot; lines.

I added #!/bin/bash at the top just to be sure and if I echo $line, it prints the lines from /etc/hosts without the colons, so it does appear to be doing something.</description>
		<content:encoded><![CDATA[<p>Hmm, not working for me.  Outputs just a bunch of blank lines separated by the &#8220;&#8212;&#8212;&#8211;&#8221; lines.</p>
<p>I added #!/bin/bash at the top just to be sure and if I echo $line, it prints the lines from /etc/hosts without the colons, so it does appear to be doing something.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
