From e9bc885c355babf7851de31db8e1920dde752993 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Wed, 7 Nov 2012 00:17:08 -0500 Subject: organize the files --- toru-path | 48 ------------------------------------------------ 1 file changed, 48 deletions(-) delete mode 100755 toru-path (limited to 'toru-path') diff --git a/toru-path b/toru-path deleted file mode 100755 index 957f49b..0000000 --- a/toru-path +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/bash - -source $(dirname $(command -v $0))/toru-utils - -TORUPATH=${T:-${TORUPATH}} -VERBOSE=${V:-false} - -if [ ! -w "$TORUPATH" ]; then - error "Toru's path isn't writable. Please check $TORUPATH" - exit 1 -fi - -LASTSYNCFILE=${TORUPATH}/lastsync.paths -PATHFILE=${TORUPATH}/paths.tch - -if [ ! -e "${PATHFILE}" ]; then - tcamgr create "${PATHFILE}" -fi - -# TODO pass other paths via flags -# ABSROOT has trailing slash -fullrepos=() -for (( i = ${#REPOS[@]}-1 ; i >= 0 ; i-- )); do - ${VERBOSE} && msg "Processing [%s]" ${REPOS[$i]} - fullrepos+=("${ABSROOT}${REPOS[$i]}") -done -pkgbuilds=($(get_pkgbuilds ${fullrepos[@]})) - -msg "Updating path cache" -msg2 "${#pkgbuilds[@]} PKGBUILDs to update" -for _pkgbuild in ${pkgbuilds[@]}; do -# plain "$_pkgbuild" - source ${_pkgbuild} >/dev/null 2>&1 || { - error "${_pkgbuild} contains errors, skipping" - continue - } - - fullpath=$(dirname ${_pkgbuild}) - - for _pkg in ${pkgbase} ${pkgname[@]} ${provides[@]}; do - $VERBOSE && msg2 "${_pkg} -> ${fullpath}" - tcamgr put ${PATHFILE} ${_pkg/[<>=]*} ${fullpath} - done - - unset pkgbase pkgname provides -done - -lastsync ${LASTSYNCFILE} -- cgit v1.2.3-54-g00ecf