~apt-fast/apt-fast/apt-fast-ro

« back to all changes in this revision

Viewing changes to apt-fast

  • Committer: GitHub
  • Author(s): NobodyXu
  • Date: 2020-04-07 13:50:36 UTC
  • Revision ID: git-v1:6f07c13a4d50119aca4f8b20fac378a0a5db2a25
Enable loading apt-fast.conf from /usr/local/etc (#174)

 * Support loading apt-fast.conf from /usr/local/etc.

Show diffs side-by-side

added added

removed removed

Lines of Context:
161
161
_DOWNLOADER='aria2c --no-conf -c -j ${_MAXNUM} -x ${_MAXCONPERSRV} -s ${_SPLITCON} -i ${DLLIST} --min-split-size=${_MINSPLITSZ} --stream-piece-selector=${_PIECEALGO} --connect-timeout=600 --timeout=600 -m0 --header "Accept: */*"'
162
162
 
163
163
# Load config file.
164
 
CONFFILE="/etc/apt-fast.conf"
165
 
if [ -e "$CONFFILE" ]; then
166
 
    source "$CONFFILE"
167
 
fi
 
164
for Prefix in /usr/local/etc /etc; do
 
165
    CONFFILE=${Prefix}/apt-fast.conf
 
166
    if [ -e "$CONFFILE" ]; then
 
167
        source "$CONFFILE"
 
168
        break
 
169
    fi
 
170
done
168
171
 
169
172
# no proxy as default
170
173
ftp_proxy=