From: Colin Watson Date: Thu, 7 Nov 2002 15:58:38 +0000 (+0000) Subject: get-kernel: Only move 'linux' out of the way if it exists as a symbolic X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~cjwatson/git?p=bin.git;a=commitdiff_plain;h=718d711b63dec4cf67add0ae35358daa3f20ab44;ds=sidebyside get-kernel: Only move 'linux' out of the way if it exists as a symbolic link. --- diff --git a/get-kernel b/get-kernel index bd9b916..a936122 100755 --- a/get-kernel +++ b/get-kernel @@ -11,5 +11,5 @@ MAJOR="${1%.*}" rm -f linux wget -c "ftp://ftp.kernel.org/pub/linux/kernel/v$MAJOR/linux-$VERSION.tar.bz2" tar xjvf "linux-$VERSION.tar.bz2" -mv linux "linux-$VERSION" +if [ -h linux ]; then mv linux "linux-$VERSION"; fi ln -s "linux-$VERSION" linux