summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2013-07-14 16:03:45 -0600
committerLuke Shumaker <LukeShu@sbcglobal.net>2013-07-14 16:03:45 -0600
commit58aac8f5c87d81df4d79c8e744ba4edbeb6e5065 (patch)
tree6d15906af8c53f9b4e3cdce62b237d94ec4b7227
parentc3dfaf79ef94cc817e12b43fecb2baf6a885ec86 (diff)
update to user libregitv20130714
-rw-r--r--Makefile1
-rw-r--r--depends_static.txt3
-rwxr-xr-xparabolaweb-download63
-rwxr-xr-xparabolaweb-update2
4 files changed, 2 insertions, 67 deletions
diff --git a/Makefile b/Makefile
index c3359dd..1a43b1e 100644
--- a/Makefile
+++ b/Makefile
@@ -7,7 +7,6 @@ confdir = /etc/conf.d
all: depends.txt
install: \
- $(DESTDIR)$(sbindir)/parabolaweb-download \
$(DESTDIR)$(sbindir)/parabolaweb-update \
$(DESTDIR)$(sbindir)/parabolaweb-fcgi \
$(DESTDIR)$(confdir)/parabolaweb \
diff --git a/depends_static.txt b/depends_static.txt
index d08e7ca..3e13323 100644
--- a/depends_static.txt
+++ b/depends_static.txt
@@ -1,6 +1,5 @@
closure-compiler # for .min.js
-git # used in parabolaweb-download
-librelib # used in parabolaweb-{download,update} (libremessages)
+libretools # used in parabolaweb-update (libremessages, libregit)
postgresql # for database
python2 # duh
python2-flup # for fcgi
diff --git a/parabolaweb-download b/parabolaweb-download
deleted file mode 100755
index dc88783..0000000
--- a/parabolaweb-download
+++ /dev/null
@@ -1,63 +0,0 @@
-#!/bin/bash
-
-# Copyright (c) 2012-2013 Pacman Development Team <pacman-dev@archlinux.org>
-# Copyright (c) 2012-2013 Luke Shumaker <lukeshu@sbcglobal.net>
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-. /etc/conf.d/parabolaweb
-. libremessages
-
-dir=$WEBDIR
-repo=$GITURL
-ref=$GITREF
-
-cd_safe() {
- if ! cd "$1"; then
- error "$(gettext "Failed to change to directory %s")" "$1"
- plain "$(gettext "Aborting...")"
- exit 1
- fi
-}
-
-download_git() {
- if [[ ! -d "$dir/.git" ]] ; then
- msg2 "$(gettext "Cloning %s %s repo...")" "${repo}" "git"
- if ! git clone "$repo" "$dir"; then
- error "$(gettext "Failure while downloading %s %s repo")" "${repo}" "git"
- plain "$(gettext "Aborting...")"
- exit 1
- fi
- else
- cd_safe "$dir"
- # Make sure we are fetching the right repo
- if [[ "$repo" != "$(git config --get remote.origin.url)" ]] ; then
- error "$(gettext "%s is not a clone of %s")" "$dir" "$repo"
- plain "$(gettext "Aborting...")"
- exit 1
- fi
- msg2 "$(gettext "Updating %s %s repo...")" "${repo}" "git"
- if ! git pull origin "$ref"; then
- # only warn on failure to allow offline builds
- warning "$(gettext "Failure while updating %s %s repo")" "${repo}" "git"
- fi
- fi
-}
-
-main() {
- [[ -d "${dir%/*}" ]] || mkdir -p "${dir%/*}"
- download_git
-}
-
-main "$@"
diff --git a/parabolaweb-update b/parabolaweb-update
index 6b27e72..498f11a 100755
--- a/parabolaweb-update
+++ b/parabolaweb-update
@@ -76,7 +76,7 @@ main() {
if [[ -d "$WEBDIR" ]]; then
clean
fi
- parabolaweb-download
+ libregit "$GITURL" "$GITREF" "$WEBDIR"
configure
update-database
update-filesystem