Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
cd $DIR_NAME problem
- X-seq: zsh-workers 13
- From: walkerjj@xxxxxxxxxxxxxxxxxxxxxxxxxxxx (Joe Walker)
- To: zsh-workers@xxxxxxxxxxxxxxx
- Subject: cd $DIR_NAME problem
- Date: Fri, 19 May 1995 11:57:23 +0100
- Phone: (+44) 793 545346
- Reply-to: walkerjj@xxxxxxxxxxxxxxxx
I found a very wierd problem by trying to run a GNU configure script.
A boiled down version is below:
% pwd
/home/jurua/walkerjj/l
% ls -l
total 2
drwxr-xr-x 2 walkerjj 512 May 11 15:43 test_dir
-rwxr-xr-x 1 walkerjj 84 May 11 15:43 test_script
% cat test_script
#!/bin/sh -x
DIR="test_dir"
echo "DIR is ($DIR)"
cd $DIR
echo "Test passed"
% test_script
DIR=test_dir
+ echo DIR is (test_dir)
DIR is (test_dir)
+ cd test_dir
test_script: test_dir: bad directory
So that is the problem: any shell script that changes to a directory using a
variable, fails.
However it get stranger:
% mv test_* ..
% cd ..
% pwd
/home/jurua/walkerjj
% test_script
DIR=test_dir
+ echo DIR is (test_dir)
DIR is (test_dir)
+ cd test_dir
+ echo Test passed
Test passed
For all of the above:
% echo $ZSH_VERSION
2.6-beta8
% uname -a
SunOS jurua 4.1.3_U1 8 sun4m
I've only edited the output to make it easier to read.
Sorry but I don't know enough about Z-shell internals yet to be able to suggest
a fix.
Thanks,
Joe.
--
____
|___ | ___ ___ EMail: walkerjj@xxxxxxxxxxxxxxxxxxxxxx
_ | |/ _ \| __| SMail: Motorola, 16 Euroway, Blagrove, SWINDON SN58YQ
| |_| | (_) | _| Tel: [+44/0] 793 54 5346
\___/ \___/|___| Fax: [+44/0] 793 54 1228
Messages sorted by:
Reverse Date,
Date,
Thread,
Author