[BACK]Return to pathdown.sh CVS log [TXT][DIR] Up to [Development] / linux-2.4-xfs / scripts

File: [Development] / linux-2.4-xfs / scripts / pathdown.sh (download)

Revision 1.1, Wed Dec 31 00:54:49 2003 UTC (13 years, 10 months ago) by cattelan
Branch: MAIN
CVS Tags: HEAD

Initial Import 2.4.24pre2

#!/bin/sh
UP=
DN=${PWD:?}
TP=${TOPDIR:?}

while [ ! $TP/$UP/. -ef $DN ] ;do
	UP=`basename $PWD`/$UP
	cd ..
	if [ "$PWD" = "/" ]; then echo "Lost"; exit 1; fi
done

echo $UP
exit 0