make_mirror.sh: support FORCE_UPDATE=yes
This commit is contained in:
parent
8bf8da5e8e
commit
806ea4b35d
1 changed files with 2 additions and 1 deletions
|
@ -301,8 +301,9 @@ components=main
|
|||
# by default, use the mmdebstrap executable in the current directory
|
||||
: "${CMD:=./mmdebstrap}"
|
||||
: "${USE_HOST_APT_CONFIG:=no}"
|
||||
: "${FORCE_UPDATE:=no}"
|
||||
|
||||
if [ -e "$oldmirrordir/dists/$DEFAULT_DIST/InRelease" ]; then
|
||||
if [ "$FORCE_UPDATE" != "yes" ] && [ -e "$oldmirrordir/dists/$DEFAULT_DIST/InRelease" ]; then
|
||||
http_code=$(curl --output /dev/null --silent --location --head --time-cond "$oldmirrordir/dists/$DEFAULT_DIST/InRelease" --write-out '%{http_code}' "$mirror/dists/$DEFAULT_DIST/InRelease")
|
||||
case "$http_code" in
|
||||
200) ;; # need update
|
||||
|
|
Loading…
Reference in a new issue