From 7c2834fb49945d6cbf4b7410cc68abf2a21e0296 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Mon, 18 Jul 2022 19:38:36 +0200 Subject: Make autopull.sh more suited for continuous integration. * autopull.sh: Support option --one-time. --- autopull.sh | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/autopull.sh b/autopull.sh index 0d08d35..4638d7b 100755 --- a/autopull.sh +++ b/autopull.sh @@ -17,8 +17,25 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -# Usage: ./autopull.sh +# Usage: ./autopull.sh [--one-time] +# +# Options: +# --one-time Optimize, assuming that the current directory will be +# used to build the current version only and will be +# thrown away afterwards. + +# Parse options. + +shallow= + +while :; do + case "$1" in + --one-time) shallow='--depth 1'; shift;; + *) break ;; + esac +done + -./gitsub.sh pull || exit 1 +./gitsub.sh pull $shallow || exit 1 echo "$0: done. Now you can run './autogen.sh'." -- cgit v1.2.1