统一将获取uri的改成apt-get

This commit is contained in:
shenmo 2023-01-06 23:53:43 +08:00
parent 4cd3ca56e0
commit 49829f8d3c

View File

@ -323,10 +323,12 @@ get_uris(){
echo "# apt-fast mirror list: $(date)" > "$DLLIST"
#NOTE: aptitude doesn't have this functionality, so we use apt-get to get
# package URIs.
case "$_APTMGR" in
apt|apt-get) uri_mgr=$_APTMGR;;
*) uri_mgr=apt-get;;
esac
# case "$_APTMGR" in
# apt|apt-get) uri_mgr=$_APTMGR;;
# *) uri_mgr=apt-get;;
# esac
# NOTE:apt可能出现变动不建议在脚本中使用因此在此统一改用apt-get
uri_mgr=apt-get
uris_full="$("$uri_mgr" "${APT_SCRIPT_WARNING[@]}" -y --print-uris "$@")"
uris_full_ret="$?"
if [ "$uris_full_ret" -ne 0 ]