[fix]修改sbin中脚本文件结束符

This commit is contained in:
2020-09-10 15:30:42 +08:00
parent 6e8d2c876b
commit 0bfc465de4
4 changed files with 7 additions and 5 deletions
+1
View File
@@ -2,6 +2,7 @@
# Ver: 1.1 by Endial Fang (endial@126.com)
#[[ ${ENV_DEBUG:-false} = true ]] && set -x
set +x
MODULE="$(basename "$0")"
+4 -5
View File
@@ -113,13 +113,11 @@ for url in $PACKAGE_URLS; do
LOG_D "Try $url/$PACKAGE"
if wget -O "$CACHE_ROOT/$PACKAGE" "$url/$PACKAGE" && [ -s "$CACHE_ROOT/$PACKAGE" ]; then
if [ -n "${PACKAGE_KEYS:-}" ]; then
wget -O "$CACHE_ROOT/$PACKAGE.asc" "$url/$PACKAGE.asc"
if [ ! -e "$CACHE_ROOT/$PACKAGE.asc" ]; then
wget -O "$CACHE_ROOT/$PACKAGE.asc" "$url/$PACKAGE.sig"
wget -O "$CACHE_ROOT/$PACKAGE.asc" "$url/$PACKAGE.asc" || wget -O "$CACHE_ROOT/$PACKAGE.asc" "$url/$PACKAGE.sign"
if [ -e "$CACHE_ROOT/$PACKAGE.asc" ]; then
break
fi
fi
success=1
break
fi
done
@@ -158,3 +156,4 @@ case "$1" in
fi
;;
esac
+1
View File
@@ -56,3 +56,4 @@ apt-get purge -y --auto-remove
apt-get autoclean -y
rm -r /var/lib/apt/lists /var/cache/apt/archives || :
+1
View File
@@ -4,3 +4,4 @@
# shell 执行参数,分别为 -e(命令执行错误则退出脚本) -u(变量未定义则报错) -x(打印实际待执行的命令行)
set -eux
cp /etc/apt/sources/sources.list.${1:-default} /etc/apt/sources.list