<?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: source equivalent in HPUX in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775674#M640733</link>
    <description>HI (again):&lt;BR /&gt;&lt;BR /&gt;&amp;gt; As mentioned, "source" is used by the scummy C shell and its descendants. A real shell uses "." to source files.&lt;BR /&gt;&lt;BR /&gt;While I wholly agree, when it comes to the "scummy C shell and its descendants", I'd certainly consider the Bash shell to be a "real shell" that can use *either* the 'source' command or the 'dot' command to achieve the same result.&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
    <pubDate>Sun, 10 Apr 2011 18:50:54 GMT</pubDate>
    <dc:creator>James R. Ferguson</dc:creator>
    <dc:date>2011-04-10T18:50:54Z</dc:date>
    <item>
      <title>source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775668#M640727</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I am writing a script that work perfectly well in linux environment as it will run&lt;BR /&gt;&lt;BR /&gt;source file.txt&lt;BR /&gt;&lt;BR /&gt;Is there an HPUX equivalent as I need to include that file to the script?</description>
      <pubDate>Sat, 09 Apr 2011 21:27:34 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775668#M640727</guid>
      <dc:creator>kholikt</dc:creator>
      <dc:date>2011-04-09T21:27:34Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775669#M640728</link>
      <description>&lt;!--!*#--&gt;&amp;gt; [...] in HPUX&lt;BR /&gt;&lt;BR /&gt;      uname -a&lt;BR /&gt;&lt;BR /&gt;&amp;gt; I am writing a script [...]&lt;BR /&gt;&lt;BR /&gt;With my weak psychic powers, I can't see it.&lt;BR /&gt;I can't even see its first line (the line&lt;BR /&gt;with the "#!").&lt;BR /&gt;&lt;BR /&gt;&amp;gt; [...] linux environment [...]&lt;BR /&gt;&lt;BR /&gt;      uname -a&lt;BR /&gt;&lt;BR /&gt;&amp;gt; Is there an HPUX equivalent [...]&lt;BR /&gt;&lt;BR /&gt;No, but there's probably a _shell_&lt;BR /&gt;equivalent, if only we knew which shell(s)&lt;BR /&gt;you were using.  if "source" doesn't work in&lt;BR /&gt;your shell, then I'd suggest ".":&lt;BR /&gt;&lt;BR /&gt;      .   file.txt</description>
      <pubDate>Sat, 09 Apr 2011 21:43:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775669#M640728</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2011-04-09T21:43:57Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775670#M640729</link>
      <description>run it with .  before it</description>
      <pubDate>Sun, 10 Apr 2011 00:41:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775670#M640729</guid>
      <dc:creator>Emil Velez</dc:creator>
      <dc:date>2011-04-10T00:41:09Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775671#M640730</link>
      <description>&lt;!--!*#--&gt;&amp;gt; run it with . before it&lt;BR /&gt;&lt;BR /&gt;Run what how, with . before what???&lt;BR /&gt;&lt;BR /&gt;What, exactly, did this contribution actually&lt;BR /&gt;contribute here?  Was your dot easier to read&lt;BR /&gt;than my dot?  (And I thought that _I_ had too&lt;BR /&gt;much time to kill.)</description>
      <pubDate>Sun, 10 Apr 2011 00:51:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775671#M640730</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2011-04-10T00:51:55Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775672#M640731</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;On Linux and Apple systems, the 'bash' shell is the default shell.  As such it has the 'source' as well as the 'dot' command, both of which do the same thing.&lt;BR /&gt;&lt;BR /&gt;HP-UX's default shell is a POSIX shell closer to the Korn shell and found in '/usr/bin/sh' or '/sbin/sh' for 'root'.  You can still specify an interpreter ("she-bang") line of simply '/bin/sh' since this is a symlink to '/usr/bin/sh' in HP-UX.&lt;BR /&gt;&lt;BR /&gt;If you want to include a file (very commonly variable declarations and assignments) into another script, you speak of "sourcing" or reading it with the 'dot' command:&lt;BR /&gt;&lt;BR /&gt;#!/bin/sh&lt;BR /&gt;...&lt;BR /&gt;# include the "mystuff' file here:&lt;BR /&gt;. /usr/local/bin/mystuff&lt;BR /&gt;echo "now continuing..."&lt;BR /&gt;...&lt;BR /&gt;&lt;BR /&gt;Notice the 'dot' followed by whitespace, followed by the file to be included ('sourced' or read, whatever term you prefer).&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...&lt;BR /&gt;</description>
      <pubDate>Sun, 10 Apr 2011 14:39:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775672#M640731</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2011-04-10T14:39:05Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775673#M640732</link>
      <description>As mentioned, "source" is used by the scummy C shell and its descendants.  A real shell uses "." to source files.</description>
      <pubDate>Sun, 10 Apr 2011 18:12:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775673#M640732</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2011-04-10T18:12:58Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775674#M640733</link>
      <description>HI (again):&lt;BR /&gt;&lt;BR /&gt;&amp;gt; As mentioned, "source" is used by the scummy C shell and its descendants. A real shell uses "." to source files.&lt;BR /&gt;&lt;BR /&gt;While I wholly agree, when it comes to the "scummy C shell and its descendants", I'd certainly consider the Bash shell to be a "real shell" that can use *either* the 'source' command or the 'dot' command to achieve the same result.&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Sun, 10 Apr 2011 18:50:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775674#M640733</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2011-04-10T18:50:54Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775675#M640734</link>
      <description>hi,&lt;BR /&gt;&lt;BR /&gt;I have tried the . dot to source file but it doesn't seem to work in my HPUX but work fine in Linux.&lt;BR /&gt;&lt;BR /&gt;config.txt&lt;BR /&gt;HOST=myserver&lt;BR /&gt;&lt;BR /&gt;script&lt;BR /&gt;#!/bin/sh&lt;BR /&gt;. config.txt&lt;BR /&gt;echo $HOST&lt;BR /&gt;&lt;BR /&gt;I get the the config.txt not found error.  Any idea why</description>
      <pubDate>Mon, 11 Apr 2011 06:15:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775675#M640734</guid>
      <dc:creator>kholikt</dc:creator>
      <dc:date>2011-04-11T06:15:38Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775676#M640735</link>
      <description>&amp;gt;I have tried the . to source file but it doesn't seem to work in my HP-UX&lt;BR /&gt;&amp;gt;. config.txt&lt;BR /&gt;&amp;gt;I get the the config.txt not found error.&lt;BR /&gt;&lt;BR /&gt;Why aren't you using an absolute path to config.txt?&lt;BR /&gt;Either it must be in $PATH or it must absolute or relative.</description>
      <pubDate>Mon, 11 Apr 2011 07:15:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775676#M640735</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2011-04-11T07:15:24Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775677#M640736</link>
      <description>The reason for that I will consider pass the config.txt to the script as argument.&lt;BR /&gt;&lt;BR /&gt;for example, script.sh config.txt&lt;BR /&gt;it make the maintenance easier as I only need one script but many config.txt to cater for different server</description>
      <pubDate>Mon, 11 Apr 2011 07:24:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775677#M640736</guid>
      <dc:creator>kholikt</dc:creator>
      <dc:date>2011-04-11T07:24:40Z</dc:date>
    </item>
    <item>
      <title>Re: source equivalent in HPUX</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775678#M640737</link>
      <description>&amp;gt;I will pass the config.txt to the script as argument.&lt;BR /&gt;&lt;BR /&gt;Then you have to pass in ./config.txt or $PWD/config.txt.&lt;BR /&gt;&lt;BR /&gt;Or you have to add "." to PATH inside your script.</description>
      <pubDate>Mon, 11 Apr 2011 09:05:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/source-equivalent-in-hpux/m-p/4775678#M640737</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2011-04-11T09:05:24Z</dc:date>
    </item>
  </channel>
</rss>

