]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
make-debs.sh: clean dir to avoid build deb packages error
authorChangcheng Liu <changcheng.liu@intel.com>
Wed, 21 Nov 2018 12:14:16 +0000 (20:14 +0800)
committerChangcheng Liu <changcheng.liu@intel.com>
Sat, 24 Nov 2018 05:17:12 +0000 (13:17 +0800)
Without this patch, it'll hit build error in the 2nd time.
Example:
make-deb.sh  #no error: first time
make-deb.sh  #hit error: second time

Signed-off-by: Changcheng Liu <changcheng.liu@intel.com>
make-debs.sh

index a8bd786766b9bbbd2557826864b26e436edbe861..5a7ca1aff5c8bd5932a656393b3066ed530350af 100755 (executable)
@@ -19,7 +19,7 @@ set -xe
 base=${1:-/tmp/release}
 codename=$(lsb_release -sc)
 releasedir=$base/$(lsb_release -si)/WORKDIR
-rm -fr $releasedir
+rm -fr $(dirname $releasedir)
 mkdir -p $releasedir
 #
 # remove all files not under git so they are not