Re: bash in perl

2009-02-11 Thread Nikhil Babu
I agree and i accept my folly. Thanks [?] I guess being a novice clearly shows. Forever Nikhil Babu On Tue, Feb 10, 2009 at 7:50 PM, Chas. Owens wrote: > On Tue, Feb 10, 2009 at 04:03, Nikhil Babu wrote: > > Hi, > > > > you can very well try the following > > > > $x = ENV{'PWD'}; > > > >

Re: bash in perl

2009-02-10 Thread Chas. Owens
On Tue, Feb 10, 2009 at 04:03, Nikhil Babu wrote: > Hi, > > you can very well try the following > > $x = ENV{'PWD'}; > > this reads the present working directory from the $PWD environment > variable. snip Relying on environment variables is as bad as calling external programs. The Cwd module is

Re: bash in perl

2009-02-10 Thread Nikhil Babu
Hi, you can very well try the following $x = ENV{'PWD'}; this reads the present working directory from the $PWD environment variable. On Feb 7, 6:59 pm, pouliakh...@gmail.com (Pouliakhina) wrote: > Hello, > > I try to write the name of the current directory in $x: > > $x = system ("pwd"); > >

Re: bash in perl

2009-02-07 Thread Owen
> Hello, > > I try to write the name of the current directory in $x: > > $x = system ("pwd"); > > But it doesn't work. It also doesn't work in all these combinations:  > $x = 'system("pwd")'; > $x = system("`pwd`"); > > Can You help me to write the result of 'pwd' in $x? Where is 'pwd'?

Re: bash in perl

2009-02-07 Thread oryann9
- Original Message From: pouliakhina To: beginners@perl.org Sent: Saturday, February 7, 2009 8:59:56 AM Subject: bash in perl Hello, I try to write the name of the current directory in $x: $x = system ("pwd"); But it doesn't work. It also doesn't work in all thes

Re: bash in perl

2009-02-07 Thread Chas. Owens
On Sat, Feb 7, 2009 at 08:59, pouliakhina wrote: > Hello, > > I try to write the name of the current directory in $x: > > $x = system ("pwd"); > > But it doesn't work. It also doesn't work in all these combinations: >  > $x = 'system("pwd")'; > $x = system("`pwd`"); > > Can You help me to write

bash in perl

2009-02-07 Thread pouliakhina
Hello, I try to write the name of the current directory in $x: $x = system ("pwd"); But it doesn't work. It also doesn't work in all these combinations:  $x = 'system("pwd")'; $x = system("`pwd`"); Can You help me to write the result of 'pwd' in $x? Thank You, Irina -- To unsubscribe, e