mirror of
https://github.com/isc-projects/bind9.git
synced 2026-06-11 12:00:00 -04:00
update kit.sh from master
This commit is contained in:
parent
51dc1b4562
commit
e86ad3801e
1 changed files with 13 additions and 23 deletions
36
util/kit.sh
36
util/kit.sh
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Copyright (C) 2004, 2007-2010, 2012, 2013 Internet Systems Consortium, Inc. ("ISC")
|
||||
# Copyright (C) 2004, 2007-2010, 2012-2014 Internet Systems Consortium, Inc. ("ISC")
|
||||
# Copyright (C) 2000-2003 Internet Software Consortium.
|
||||
#
|
||||
# Permission to use, copy, modify, and/or distribute this software for any
|
||||
|
|
@ -92,21 +92,19 @@ test -f $verdir/version || {
|
|||
rm $verdir/version
|
||||
rmdir $verdir
|
||||
|
||||
shorthash=`git ls-remote $repo refs/heads/$tag | cut -c1-8`
|
||||
if [ -z "$shorthash" ]; then
|
||||
shorthash=`git ls-remote $repo refs/tags/$tag | cut -c1-8`
|
||||
fi
|
||||
if [ -z "$shorthash" ]; then
|
||||
echo "Unable to determine hash for $tag, aborting."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if $snapshot
|
||||
then
|
||||
set `date -u +'%Y%m%d%H%M%S %Y/%m/%d %H:%M:%S UTC'`
|
||||
dstamp=$1
|
||||
RELEASETYPE=s
|
||||
RELEASEVER=${dstamp}${releasetag}
|
||||
shift
|
||||
case $tag in
|
||||
master)
|
||||
tag="$@"
|
||||
;;
|
||||
*)
|
||||
tag="$@"
|
||||
;;
|
||||
esac
|
||||
RELEASEVER=${shorthash}
|
||||
fi
|
||||
|
||||
version=${MAJORVER}.${MINORVER}${PATCHVER:+.}${PATCHVER}${RELEASETYPE}${RELEASEVER}${EXTENSIONS}
|
||||
|
|
@ -123,14 +121,6 @@ test ! -d $topdir || {
|
|||
mkdir $topdir || exit 1
|
||||
|
||||
git archive --format=tar $remote $tag | ( cd $topdir; tar xf -)
|
||||
shorthash=`git ls-remote $repo refs/heads/$tag | cut -c1-8`
|
||||
if [ -z "$shorthash" ]; then
|
||||
shorthash=`git ls-remote $repo refs/tags/$tag | cut -c1-8`
|
||||
fi
|
||||
if [ -z "$shorthash" ]; then
|
||||
echo "Unable to determine hash for $tag, aborting."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cd $topdir || exit 1
|
||||
|
||||
|
|
@ -159,8 +149,8 @@ rm -rf TODO EXCLUDED conftools doc/design doc/dev doc/draft doc/expired \
|
|||
lib/lwres/man/resolver.5 contrib/zkt/doc/rfc5011.txt \
|
||||
bin/tests/system/relay lib/cfg
|
||||
|
||||
# Remove everything but mksymtbl.pl from util
|
||||
find util -name mksymtbl.pl -prune -o -type f -print | xargs rm -f
|
||||
# Remove everything but mksymtbl.pl and bindkeys.pl from util
|
||||
find util -name bindkeys.pl -o -name mksymtbl.pl -prune -o -type f -print | xargs rm -f
|
||||
find util -depth -type d -print | xargs rmdir 2>/dev/null
|
||||
|
||||
# Remove all .gitignore files
|
||||
|
|
|
|||
Loading…
Reference in a new issue