aboutsummaryrefslogtreecommitdiff
path: root/testretrieve.sh
blob: 05bfdb17269f01a3978ae4b2d2e8aab4349b47f2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/bash
# retrieve files $3-($3+$2), outputting to `out'
echo "Retrieve:"

stop=$(echo "$3+$2-1" | bc)

for i in $(seq $3 $stop)
do
    $1 -u 1 -k a retrievefile -f $i -o out -p > /dev/null
    if [[ $? -ne 0 ]]
    then
        echo "Request failed!"
    fi
done