* Indirect t-archive-none and t-archive-query via this variable
* Rename t-archive-updated; it is for callers that have updated
aq/package.$suite.$p. There is one out-of-lib caller.
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
+: ${t_archive_method:=aq}
: ${tagpfx:=archive/test-dummy}
: ${suitespecs:=sid:unstable}
: ${tagpfx:=archive/test-dummy}
: ${suitespecs:=sid:unstable}
t-archive-none () {
t-select-package $1
t-archive-none () {
t-select-package $1
+ t-archive-none-$t_archive_method
+}
+t-archive-none-aq () {
mkdir -p $tmp/aq/dsc_in_suite $tmp/mirror/pool/main
: >$tmp/aq/suites
mkdir -p $tmp/aq/dsc_in_suite $tmp/mirror/pool/main
: >$tmp/aq/suites
local sname=${suitespec#*:}
>$tmp/aq/package.$suite.$p
local sname=${suitespec#*:}
>$tmp/aq/package.$suite.$p
- t-archive-updated $suite $p
+ t-aq-archive-updated $suite $p
- t-archive-updated new $p
+ t-aq-archive-updated new $p
ln -sf $suite $tmp/aq/dsc_in_suite/$sname
ln -sf $suite $tmp/aq/dsc_in_suite/$sname
+t-aq-archive-updated () {
local suite=$1
local p=$2
local suitedir=$tmp/aq/dsc_in_suite/$suite
local suite=$1
local p=$2
local suitedir=$tmp/aq/dsc_in_suite/$suite
t-archive-query () {
local suite=${1-sid}
local dscf=main/${p}_${v}.dsc
t-archive-query () {
local suite=${1-sid}
local dscf=main/${p}_${v}.dsc
+ t-archive-query-$t_archive_method "$suite" "$p" "$v" "$dscf"
+}
+t-archive-query-aq () {
+ local suite=$1
+ local p=$2
+ local v=$3
+ local dscf=$4
local sha=`sha256sum <$tmp/mirror/pool/$dscf`
echo "${v} ${sha% -} $dscf" >>$tmp/aq/package.$suite.${p}
local sha=`sha256sum <$tmp/mirror/pool/$dscf`
echo "${v} ${sha% -} $dscf" >>$tmp/aq/package.$suite.${p}
- t-archive-updated $suite $p
+ t-aq-archive-updated $suite $p
local from=${2:-sid}
local to=${3:-stable}
egrep "^${vm//./\\.}" aq/package.$from.$p >>aq/package.$to.$p
local from=${2:-sid}
local to=${3:-stable}
egrep "^${vm//./\\.}" aq/package.$from.$p >>aq/package.$to.$p
- t-archive-updated $to $p
+ t-aq-archive-updated $to $p