<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/12382" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2006-09-05T10:21:17-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/12382</id>

		<entry>
		<author><name><![CDATA[BCyo+8C4]]></name></author>
		<updated>2006-09-05T10:21:17-04:00</updated>

		<published>2006-09-05T10:21:17-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=66137#p66137</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=66137#p66137"/>
		<title type="html"><![CDATA[exec awk problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=66137#p66137"><![CDATA[
got it. it was the ' chars + the space after &gt;<br><br>working code:<div class="codebox"><p>Code: </p><pre><code>exec awk -f alfa.awk -v was={tr}{td}$mask bans-$chan.txt &gt;bans-$chan-tmp.txtexec mv bans-$chan-tmp.txt bans-$chan.txt</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8166">BCyo+8C4</a> — Tue Sep 05, 2006 10:21 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[rosc2112]]></name></author>
		<updated>2006-09-04T14:26:51-04:00</updated>

		<published>2006-09-04T14:26:51-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=66123#p66123</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=66123#p66123"/>
		<title type="html"><![CDATA[exec awk problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=66123#p66123"><![CDATA[
<blockquote class="uncited"><div>the problem is not the brackets, even this test code doesn't work when called from tcl:<div class="codebox"><p>Code: </p><pre><code>exec awk -f alfa.awk -v was='test' bans-#test.txt &gt; bans-#test-tmp.txt</code></pre></div></div></blockquote>Just curious, what does your awk script try to accomplish and why could it not be done in native tcl code?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7395">rosc2112</a> — Mon Sep 04, 2006 2:26 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[rosc2112]]></name></author>
		<updated>2006-09-04T14:24:48-04:00</updated>

		<published>2006-09-04T14:24:48-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=66122#p66122</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=66122#p66122"/>
		<title type="html"><![CDATA[exec awk problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=66122#p66122"><![CDATA[
Tcl Built-In Commands - exec manual page<br><br> If an arg (or pair of args) has one of the forms described below then it is used by exec to control the flow of input and output among the subbprocess(es). Such arguments will not be passed to the subprocess(es). In forms such as ``&lt; fileName'' fileName may either be in a separate argument from ``&lt;'' or in the same argument with no intervening space (i.e. ``&lt;fileName'').<br><br><br>   &gt; fileName<br>          Standard output from the last command is redirected to the file named fileName, overwriting its previous contents.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7395">rosc2112</a> — Mon Sep 04, 2006 2:24 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[demond]]></name></author>
		<updated>2006-09-04T12:42:17-04:00</updated>

		<published>2006-09-04T12:42:17-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=66121#p66121</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=66121#p66121"/>
		<title type="html"><![CDATA[exec awk problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=66121#p66121"><![CDATA[
my guess is that space between the redirection character and output file name is not being interpreted as in shell<br><br>try without it, i.e. <em class="text-italics">&gt;bans-$chan-tmp.txt</em><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5056">demond</a> — Mon Sep 04, 2006 12:42 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[BCyo+8C4]]></name></author>
		<updated>2006-09-04T06:33:42-04:00</updated>

		<published>2006-09-04T06:33:42-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=66113#p66113</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=66113#p66113"/>
		<title type="html"><![CDATA[exec awk problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=66113#p66113"><![CDATA[
the problem is not the brackets, even this test code doesn't work when called from tcl:<div class="codebox"><p>Code: </p><pre><code>exec awk -f alfa.awk -v was='test' bans-#test.txt &gt; bans-#test-tmp.txt</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8166">BCyo+8C4</a> — Mon Sep 04, 2006 6:33 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[demond]]></name></author>
		<updated>2006-09-04T00:13:25-04:00</updated>

		<published>2006-09-04T00:13:25-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=66108#p66108</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=66108#p66108"/>
		<title type="html"><![CDATA[exec awk problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=66108#p66108"><![CDATA[
escape curly braces with backslashes<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5056">demond</a> — Mon Sep 04, 2006 12:13 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[BCyo+8C4]]></name></author>
		<updated>2006-09-03T11:20:57-04:00</updated>

		<published>2006-09-03T11:20:57-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=66089#p66089</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=66089#p66089"/>
		<title type="html"><![CDATA[exec awk problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=66089#p66089"><![CDATA[
Hi,<br>I'd like to call awk from a tcl script, but for some reason it doesn't work. No error message returned.<br><br>In my tcl I have this line to call the script: <div class="codebox"><p>Code: </p><pre><code>exec awk -f alfa.awk -v was='{tr}{td}$mask' bans-$chan.txt &gt; bans-$chan-tmp.txt</code></pre></div>All parameters are send to the script correctly and the awk command works fine like this when called from bash.<br>Changing the script to point to an invalid .awk file makes it throw an error, so it seems awk is actually run. It just doesn't do what it's supposed to do when called from tcl.<br><br>Anyone got an idea what I got wrong?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8166">BCyo+8C4</a> — Sun Sep 03, 2006 11:20 am</p><hr />
]]></content>
	</entry>
	</feed>
