diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2022-11-21 13:17:16 +0100 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2022-11-21 13:17:16 +0100 |
commit | 15d7b8dc21e77acc343a94d7869764caae7f497d (patch) | |
tree | c629ef8f47dce81ed981f2022ae72c1b9024e662 | |
parent | 3e506474a816e0c30b8cf0f30afb0f7f5059d881 (diff) | |
download | alpine-conf-15d7b8dc21e77acc343a94d7869764caae7f497d.zip |
setup-apkrepos: avoid run interactive with -r|-f|-1
Avoid run interactive if the non-interactive modes fails
-rw-r--r-- | setup-apkrepos.in | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/setup-apkrepos.in b/setup-apkrepos.in index 63b1600..9112295 100644 --- a/setup-apkrepos.in +++ b/setup-apkrepos.in @@ -218,7 +218,13 @@ if $add_fastest; then add_fastest_mirror && changed=true fi -while ! $changed; do +if $add_first || $add_random || $add_fastest; then + interactive=false +else + interactice=true +fi + +while $interactive && ! $changed; do if [ -z "$MIRRORS" ]; then MIRRORS=$(wget -qO- $MIRRORS_URL) fi |