From e4e9960d734c8cbe5630454701f0289e0ed68d07 Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Wed, 5 Feb 2014 00:39:14 +0100 Subject: fix config Signed-off-by: Florian Pritz --- config | 2 ++ db-functions | 7 ++++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/config b/config index 3df6c95..f34bd33 100644 --- a/config +++ b/config @@ -1,4 +1,6 @@ FTP_BASE="/srv/ftp" +HISTORYREPO="" +DBSCRIPTS_USER=dbscripts SVNREPO='' SVNUSER='' PKGREPOS=() diff --git a/db-functions b/db-functions index 351aaeb..6bd3b5d 100644 --- a/db-functions +++ b/db-functions @@ -559,7 +559,7 @@ arch_history_add() { local pkgbase=$(getpkgbase "$pkgfile") local pkgver=$(getpkgver "$pkgfile") - local history_file="$GITREPO/$repo/$tarch/$pkgname" + local history_file="$HISTORYREPO/$repo/$tarch/$pkgname" mkdir -p "${history_file%/*}" echo "$pkgbase $pkgver" > "$history_file" @@ -572,7 +572,7 @@ arch_history_remove() { local pkgname="$2" local tarch="$3" - local history_file="$GITREPO/$repo/$tarch/$pkgname" + local history_file="$HISTORYREPO/$repo/$tarch/$pkgname" [[ -f "$history_file" ]] || return 1 @@ -580,7 +580,7 @@ arch_history_remove() { } arch_history_commit() { - pushd "$GITREPO" + pushd "$HISTORYREPO" if ((${#HISTORY_add_files[@]} > 0)); then git add -- "${HISTORY_add_files[@]}" fi @@ -627,6 +627,7 @@ get_file_from_pkgrepo() { # TODO: implement svn/git extraction # for git: cd $whereever; git show $tag:$filename curl -s https://projects.archlinux.org/svntogit/community.git/plain/trunk/$filename?h=packages/$pkgbase + # TODO: this requires us to restructure the repos #arch_svn cat "${SVNREPO}/${_pkgbase}/tags/$tag/$filename" } -- cgit v1.2.3-24-g4f1b