<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Simulate &amp;quot;Enter&amp;quot; Key in script in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866871#M706409</link>
    <description>The ci -l filename command will execute whether I stick an echo statement in front of it or not.&lt;BR /&gt;&lt;BR /&gt;Beyond that point the process is hanging no matter what variations of echo or END_OF_DATA statements I try.&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Fri, 22 Oct 2004 13:12:05 GMT</pubDate>
    <dc:creator>Dick Fischer</dc:creator>
    <dc:date>2004-10-22T13:12:05Z</dc:date>
    <item>
      <title>Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866867#M706405</link>
      <description>We use RCS as our program configuration management software in unix.  I'm attempting to create a unix script to automate the checkin process of 100+ programs that are modified every time there's a timechange.  &lt;BR /&gt;&lt;BR /&gt;Typically one keys text into RCS, and RCS waits for the "Enter" key before going on to the next command.  The checkin process does not complete until a period (.) is entered on the final step.  The unix script would have a series of RCS commands for each of the 100+ modules.  Is there a way of coding the "Enter" key into the script?  I've tried a few things, but the script just hangs after the first command.&lt;BR /&gt;&lt;BR /&gt;A typical series of commands would be:&lt;BR /&gt;&lt;BR /&gt;ci -l filename   &amp;lt;== checkin and lock filename&lt;BR /&gt;&lt;BR /&gt;???  &amp;lt;== Hit Enter&lt;BR /&gt;&lt;BR /&gt;Time change   &amp;lt;== text keyed in explaining what the modification was&lt;BR /&gt;&lt;BR /&gt;???  &amp;lt;== Hit Enter&lt;BR /&gt;&lt;BR /&gt;Changed by yours truly  &amp;lt;== second line of text keyed in&lt;BR /&gt;&lt;BR /&gt;???  &amp;lt;== Hit Enter&lt;BR /&gt;&lt;BR /&gt;.   &amp;lt;== Period (.) to indicate that I'm done entering text&lt;BR /&gt;&lt;BR /&gt;???  &amp;lt;== Hit Enter&lt;BR /&gt;&lt;BR /&gt;The last "Enter" will indicate that I'm done with the checkin, and RCS will be exited.</description>
      <pubDate>Fri, 22 Oct 2004 11:22:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866867#M706405</guid>
      <dc:creator>Dick Fischer</dc:creator>
      <dc:date>2004-10-22T11:22:27Z</dc:date>
    </item>
    <item>
      <title>Re: Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866868#M706406</link>
      <description>You can do this with an expect script...&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://hpux.ee.ualberta.ca/hppd/hpux/Tcl/expect-5.41/" target="_blank"&gt;http://hpux.ee.ualberta.ca/hppd/hpux/Tcl/expect-5.41/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Rgds...Geoff</description>
      <pubDate>Fri, 22 Oct 2004 11:31:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866868#M706406</guid>
      <dc:creator>Geoff Wild</dc:creator>
      <dc:date>2004-10-22T11:31:54Z</dc:date>
    </item>
    <item>
      <title>Re: Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866869#M706407</link>
      <description>Hi&lt;BR /&gt;&lt;BR /&gt;Try the following:&lt;BR /&gt;echo "\n\n\n...\n"| your_script&lt;BR /&gt;or this:&lt;BR /&gt;your_script&amp;lt;&amp;lt;$$END_OF_INPUT&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;$$END_OF_INPUT&lt;BR /&gt;&lt;BR /&gt;Each empty string is ENTER&lt;BR /&gt;&lt;BR /&gt;HTH</description>
      <pubDate>Fri, 22 Oct 2004 12:20:43 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866869#M706407</guid>
      <dc:creator>Victor Fridyev</dc:creator>
      <dc:date>2004-10-22T12:20:43Z</dc:date>
    </item>
    <item>
      <title>Re: Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866870#M706408</link>
      <description>So doing something like-&lt;BR /&gt;echo "\n\n\n\n" | ci -l filename &lt;BR /&gt; &lt;BR /&gt;Doesn't work?&lt;BR /&gt; &lt;BR /&gt;Hmmm... Maybe ci reads from STDERR. Try-&lt;BR /&gt;echo "\n\n\n\n" | ci -l filename 2&amp;lt;&amp;amp;0&lt;BR /&gt; &lt;BR /&gt;See if that works...&lt;BR /&gt; &lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Fri, 22 Oct 2004 12:21:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866870#M706408</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2004-10-22T12:21:35Z</dc:date>
    </item>
    <item>
      <title>Re: Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866871#M706409</link>
      <description>The ci -l filename command will execute whether I stick an echo statement in front of it or not.&lt;BR /&gt;&lt;BR /&gt;Beyond that point the process is hanging no matter what variations of echo or END_OF_DATA statements I try.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 22 Oct 2004 13:12:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866871#M706409</guid>
      <dc:creator>Dick Fischer</dc:creator>
      <dc:date>2004-10-22T13:12:05Z</dc:date>
    </item>
    <item>
      <title>Re: Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866872#M706410</link>
      <description>If "ci" is like "passwd" command, then as stated before, "expect" utility is the best way to drive the input.&lt;BR /&gt; &lt;BR /&gt;-- Rod Hills</description>
      <pubDate>Fri, 22 Oct 2004 13:23:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866872#M706410</guid>
      <dc:creator>Rodney Hills</dc:creator>
      <dc:date>2004-10-22T13:23:47Z</dc:date>
    </item>
    <item>
      <title>Re: Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866873#M706411</link>
      <description>I am not sure if I fuly understand your requirement&lt;BR /&gt;&lt;BR /&gt;I will give it a try :-)&lt;BR /&gt;&lt;BR /&gt;ci -l filename &amp;lt;&lt;EOF&gt;&lt;/EOF&gt;echo "Time Change"&lt;BR /&gt;echo "Changed by yours truly"&lt;BR /&gt;echo "."&lt;BR /&gt;EOF&lt;BR /&gt;&lt;BR /&gt;will this work for you ?</description>
      <pubDate>Fri, 22 Oct 2004 13:32:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866873#M706411</guid>
      <dc:creator>Sundar_7</dc:creator>
      <dc:date>2004-10-22T13:32:08Z</dc:date>
    </item>
    <item>
      <title>Re: Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866874#M706412</link>
      <description>I would think that a "here doc" would work in a script:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;A typical series of commands would be:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;################################&lt;BR /&gt;ci -l filename &amp;lt;&lt;EOD&gt;&lt;/EOD&gt;&lt;BR /&gt;text explaining what the mod was&lt;BR /&gt;second line of text&lt;BR /&gt;.&lt;BR /&gt;&lt;BR /&gt;EOD&lt;BR /&gt;################################&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;The blank lines above should feed in as "Enter" to the ci program.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 22 Oct 2004 14:38:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866874#M706412</guid>
      <dc:creator>Tom Danzig</dc:creator>
      <dc:date>2004-10-22T14:38:51Z</dc:date>
    </item>
    <item>
      <title>Re: Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866875#M706413</link>
      <description>The EOD solution did the trick.  Thank you all for your suggestions.</description>
      <pubDate>Fri, 22 Oct 2004 16:48:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866875#M706413</guid>
      <dc:creator>Dick Fischer</dc:creator>
      <dc:date>2004-10-22T16:48:44Z</dc:date>
    </item>
    <item>
      <title>Re: Simulate "Enter" Key in script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866876#M706414</link>
      <description>Thread is closed.  Thanks again for taking the time to give suggestions.</description>
      <pubDate>Fri, 22 Oct 2004 16:52:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/simulate-quot-enter-quot-key-in-script/m-p/4866876#M706414</guid>
      <dc:creator>Dick Fischer</dc:creator>
      <dc:date>2004-10-22T16:52:54Z</dc:date>
    </item>
  </channel>
</rss>

