delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2003/11/02/12:25:14

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Date: Mon, 03 Nov 2003 02:24:44 +0900
From: Seiji Yoneda <s-yoneda AT spn1 DOT speednet DOT ne DOT jp>
To: cygwin at cygwin dot com <cygwin AT cygwin DOT com>
Subject: bash script does't work.
Message-Id: <20031103014206.4964.S-YONEDA@spn1.speednet.ne.jp>
MIME-Version: 1.0
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id hA2HPA6g002234

Hi,

I'm using bash 2.05a.0(2) on win2k pro and I'm running into problems
that the bash script doesn't work as I expected.

My bash script is as follows,  

<---------------- from here the script (ora8i.sh) start
#!/usr/bin/bash

ORA_HOME='/c/oracle/ora817'
export ORA_HOME
PATH=${ORA_HOME}/bin:${PATH}
export PATH
printenv PATH 
<---------------- here the script end

When execute these commands step by step, PATH environment variable
changes. But execute above bash script, PATH environment variable doesn't
change.
What's wrong ? If someone has some idea about this problem, please help me!

$ printenv ORA_HOME   <---------------- Before execution of script
    <----------- Before execution of script, ORA_HOME has nothing.
$ printenv PATH
/usr/local/pgsql/bin:/usr/local/pgsql/lib:/usr/local/bin:/usr/bin:/bin:/c/j2sdk1
.4.2_02/bin:/c/WINNT/system32:/c/WINNT:/c/WINNT/System32/Wbem

$ ora8i.sh        <---------------- Execute this script
/c/oracle/ora817/bin:/usr/local/pgsql/bin:/usr/local/pgsql/lib:/usr/local/bin:/u
sr/bin:/bin:/c/j2sdk1.4.2_02/bin:/c/WINNT/system32:/c/WINNT:/c/WINNT/System32/Wb
em

$ printenv ORA_HOME   <---------------- After execution of script
    <----------- After execution, ORA_HOME has nothing !!
$ printenv PATH   <---------------- After execution, PATH does't change!!
/usr/local/pgsql/bin:/usr/local/pgsql/lib:/usr/local/bin:/usr/bin:/bin:/c/j2sdk1
.4.2_02/bin:/c/WINNT/system32:/c/WINNT:/c/WINNT/System32/Wbem

------------------------------------
Seiji Yoneda <s-yoneda AT spn1 DOT speednet DOT ne DOT jp>
------------------------------------



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019