From: Carl Worth Date: Wed, 10 Mar 2010 23:27:59 +0000 (-0800) Subject: lib: Add script to import getdate source from a gnulib repository. X-Git-Url: https://git.cworth.org/git?p=obsolete%2Fnotmuch-old;a=commitdiff_plain;h=7e5443e990f6cb1ebc2190d4276415725de7203c lib: Add script to import getdate source from a gnulib repository. We're planning to copy in the getdate implementation from gnulib. This import script will simplify the process of updating this source given future changes to gnulib. --- diff --git a/lib/getdate/import b/lib/getdate/import new file mode 100755 index 00000000..e3a789c3 --- /dev/null +++ b/lib/getdate/import @@ -0,0 +1,37 @@ +#!/bin/sh +set -e + +GNULIB=${HOME}/src/gnulib + +if [ ! -d ${GNULIB} ]; then + cat <&2 +Error: No gnulib checkout found at ${GNULIB} + +Please checkout gnulib and/or update the GNULIB variable in this script. +The following command may be convenient: + + git clone git://git.sv.gnu.org/gnulib.git + +EOF + exit 1 +fi + +files="c-ctype.c + c-ctype.h + getdate.y + getdate.h + gettime.c + intprops.h + timespec.h + verify.h + xalloc.h + xalloc-die.c + xmalloc.c" + +for file in $files; do + cp ${GNULIB}/lib/$file . +done + +commit=$(cd ${GNULIB}; git rev-parse HEAD) +echo "Updated getdate source from gnulib commit:" +echo "$commit"