<?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/"
	xmlns:series="http://unfoldingneurons.com/"
		>
<channel>
	<title>Comments on: Linux script to prompt for password</title>
	<atom:link href="http://www.cyberciti.biz/faq/linux-script-to-prompt-for-password/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.cyberciti.biz/faq/linux-script-to-prompt-for-password/</link>
	<description>Every answer asks a more beautiful question.</description>
	<lastBuildDate>Sat, 20 Mar 2010 06:10:08 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Tukur Dan-Asabe</title>
		<link>http://www.cyberciti.biz/faq/linux-script-to-prompt-for-password/comment-page-1/#comment-1088</link>
		<dc:creator>Tukur Dan-Asabe</dc:creator>
		<pubDate>Thu, 19 Oct 2006 08:58:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.cyberciti.biz/faq/faq/linux-script-to-prompt-for-password.php#comment-1088</guid>
		<description>Thanks nixcraft,</description>
		<content:encoded><![CDATA[<p>Thanks nixcraft,</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: nixcraft</title>
		<link>http://www.cyberciti.biz/faq/linux-script-to-prompt-for-password/comment-page-1/#comment-106</link>
		<dc:creator>nixcraft</dc:creator>
		<pubDate>Tue, 12 Sep 2006 14:13:18 +0000</pubDate>
		<guid isPermaLink="false">http://www.cyberciti.biz/faq/faq/linux-script-to-prompt-for-password.php#comment-106</guid>
		<description>Tukur,

Assuming that your file.txt is as follows:
val1   val2   val3

Here is a shell script:
&lt;b&gt;
#!/bin/sh
while read line
do
        # store field 1
        F1=$(echo $line&#124;cut -d&quot; &quot; -f1)
        # store field 2
        F2=$(echo $line&#124;cut -d&quot; &quot; -f2)
        # store field
        F3=$(echo $line&#124;cut -d&quot; &quot; -f3)
        echo $F1 &quot; &quot; $F2 &quot; &quot; $F3
done &lt; file.txt
&lt;/b&gt;

Var $F1 $F2 and $F3 stores the value. If you need more help try out shell scripting forum @ http://forum.cyberciti.biz/</description>
		<content:encoded><![CDATA[<p>Tukur,</p>
<p>Assuming that your file.txt is as follows:<br />
val1   val2   val3</p>
<p>Here is a shell script:<br />
<b><br />
#!/bin/sh<br />
while read line<br />
do<br />
        # store field 1<br />
        F1=$(echo $line|cut -d&#8221; &#8221; -f1)<br />
        # store field 2<br />
        F2=$(echo $line|cut -d&#8221; &#8221; -f2)<br />
        # store field<br />
        F3=$(echo $line|cut -d&#8221; &#8221; -f3)<br />
        echo $F1 &#8221; &#8221; $F2 &#8221; &#8221; $F3<br />
done < file.txt<br />
</b></p>
<p>Var $F1 $F2 and $F3 stores the value. If you need more help try out shell scripting forum @ <a href="http://forum.cyberciti.biz/" rel="nofollow">http://forum.cyberciti.biz/</a></b></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tukur Dan-Asabe</title>
		<link>http://www.cyberciti.biz/faq/linux-script-to-prompt-for-password/comment-page-1/#comment-102</link>
		<dc:creator>Tukur Dan-Asabe</dc:creator>
		<pubDate>Tue, 12 Sep 2006 08:28:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.cyberciti.biz/faq/faq/linux-script-to-prompt-for-password.php#comment-102</guid>
		<description>Please I want to y1, y2 and y3 to have values piped in by the pipe (&#124;) and read to read from the file and asign them to the variables but 

export tukur=2
test is a file contain 3 columns say: aa bb cc
after excuting the following command y1, y2, y3 dont contain anythin pls could someone help?

tail -n +$tukur home/tukur/test &#124; read -r y1 y2 y3


Thank you,
Tukur Dan-Asabe.</description>
		<content:encoded><![CDATA[<p>Please I want to y1, y2 and y3 to have values piped in by the pipe (|) and read to read from the file and asign them to the variables but </p>
<p>export tukur=2<br />
test is a file contain 3 columns say: aa bb cc<br />
after excuting the following command y1, y2, y3 dont contain anythin pls could someone help?</p>
<p>tail -n +$tukur home/tukur/test | read -r y1 y2 y3</p>
<p>Thank you,<br />
Tukur Dan-Asabe.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dave</title>
		<link>http://www.cyberciti.biz/faq/linux-script-to-prompt-for-password/comment-page-1/#comment-17</link>
		<dc:creator>Dave</dc:creator>
		<pubDate>Thu, 17 Aug 2006 02:19:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.cyberciti.biz/faq/faq/linux-script-to-prompt-for-password.php#comment-17</guid>
		<description>Thanks!</description>
		<content:encoded><![CDATA[<p>Thanks!</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Dynamic Page Served (once) in 0.093 seconds -->
<!-- Cached page served by WP-Cache -->
