刚学shell,下面这个shell执行时报错: $HOME/billdata/filter2/hb4: not found.事实上这个路径是存在的.
shell代码如下:
#!/bin/sh
#test
pathname="./sp_path"
cat $pathname|while read line
do
echo "the path is $line"
cd $line
done
...全文
715打赏收藏
shell cd
刚学shell,下面这个shell执行时报错: $HOME/billdata/filter2/hb4: not found.事实上这个路径是存在的. shell代码如下: #!/bin/sh #test pathname="./sp_path" cat $pathname|while read line do echo "the path is $line" cd $line done