summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--setup-apkrepos.in7
1 files changed, 3 insertions, 4 deletions
diff --git a/setup-apkrepos.in b/setup-apkrepos.in
index 07d8e06..a692ec4 100644
--- a/setup-apkrepos.in
+++ b/setup-apkrepos.in
@@ -109,10 +109,9 @@ get_alpine_release() {
add_mirror() {
local mirror="$1"
- community_char="$([ "$enable_community" = true ] || echo -n "#")"
mkdir -p "${APKREPOS_PATH%/*}"
echo "${mirror%/}/${release}/main" >> $APKREPOS_PATH
- echo "${community_char}${mirror%/}/${release}/community" >> $APKREPOS_PATH
+ echo "${community_prefix}${mirror%/}/${release}/community" >> $APKREPOS_PATH
case "$release" in
v[0-9]*)
echo "#${mirror%/}/edge/main" >> $APKREPOS_PATH;
@@ -154,13 +153,13 @@ usage() {
}
-enable_community=false
+community_prefix="# "
add_fastest=false
add_first=false
add_random=false
while getopts "1fhr" opt; do
case $opt in
- c) enable_community=true;;
+ c) community_prefix="";;
f) add_fastest=true;;
1) add_first=true;;
h) usage;;