Make release scripts less out of date.
This commit is contained in:
parent
c18ef8807a
commit
1a8367735f
2 changed files with 9 additions and 45 deletions
|
@ -24,10 +24,13 @@ if [ "x$TIP" = "x" ]; then
|
|||
exit
|
||||
fi
|
||||
|
||||
# Charybdis wants the hg tip to be in include/serno.h, in its own format.
|
||||
MYTIP=`git log -1 --date=short --pretty=format:%cd_%h 2>/dev/null | sed -e s/-//g -e s/_/-/`
|
||||
# Charybdis wants the git head to be in include/serno.h, in its own format.
|
||||
SERNO=`git log -1 --date=format:%Y%m%d --pretty=format:%cd-%h`
|
||||
DATECODE=`git log -1 --pretty=format:%ct`
|
||||
|
||||
echo "[charybdis] Generating include/serno.h for tip $MYTIP."
|
||||
cat << _EOF_ > include/serno.h
|
||||
/* Generated automatically by makepackage. Any changes made here will be lost. */
|
||||
#define SERNO "$MYTIP"
|
||||
#define SERNO "$SERNO"
|
||||
#define DATECODE "$DATECODE"
|
||||
_EOF_
|
||||
|
|
|
@ -20,16 +20,12 @@
|
|||
#
|
||||
|
||||
if [ "x$1" = "x" ]; then
|
||||
echo "usage: $0 releasename [--automatic]"
|
||||
echo "usage: $0 releasename"
|
||||
exit
|
||||
else
|
||||
RELEASENAME="$1"
|
||||
fi
|
||||
|
||||
if [ "x$2" = "x--automatic" ]; then
|
||||
AUTOMATIC="yes"
|
||||
fi
|
||||
|
||||
TIP=`git log -1 --pretty=oneline | cut -d" " -f1`
|
||||
|
||||
WRKDIR=`pwd`
|
||||
|
@ -66,41 +62,6 @@ echo "Building $RELEASENAME.tbz2 from $RELEASENAME/"
|
|||
tar jcf $RELEASENAME.tar.bz2 $RELEASENAME/
|
||||
|
||||
rm $RELEASENAME-working.tar.gz
|
||||
rm -rf $RELEASENAME
|
||||
|
||||
PUBLISH="yes"
|
||||
|
||||
ok="0"
|
||||
if [ "x$AUTOMATIC" != "xyes" ]; then
|
||||
echo
|
||||
echo "Would you like to publish these releases now?"
|
||||
while [ $ok -eq 0 ]; do
|
||||
echo -n "[$PUBLISH] "
|
||||
|
||||
read INPUT
|
||||
case $INPUT in
|
||||
[Yy]*)
|
||||
PUBLISH="yes"
|
||||
ok=1
|
||||
;;
|
||||
[Nn]*)
|
||||
PUBLISH="no"
|
||||
ok=1
|
||||
;;
|
||||
esac
|
||||
done
|
||||
fi
|
||||
|
||||
if [ "x$PUBLISH" = "xyes" ]; then
|
||||
scp $RELEASENAME.tgz hg.atheme.org:/srv/distfiles
|
||||
scp $RELEASENAME.tbz2 hg.atheme.org:/srv/distfiles
|
||||
|
||||
echo
|
||||
echo "The releases have been published, and will be available to the entire"
|
||||
echo "distribution network within 15 minutes."
|
||||
fi
|
||||
|
||||
echo
|
||||
echo "Done. If you have any bugs to report, report them against"
|
||||
echo "the distfiles.atheme.org component at http://jira.atheme.org"
|
||||
echo "Thanks!"
|
||||
echo
|
||||
echo "Done. $RELEASENAME.tar.gz and $RELEASENAME.tar.bz2 built."
|
||||
|
|
Loading…
Reference in a new issue