📌  相关文章
📜  bash 如何下载受密码保护的文件 - Shell-Bash 代码示例

📅  最后修改于: 2022-03-11 14:49:54.863000             🧑  作者: Mango

代码示例1
# Basic syntax:
# Download a single password protected file:
wget http://url/file --user=username --password=password --directory-prefix=/path/to/output/directory

# Recursively download a directory of password protected files:
wget -r --no-parent http://url/directory/ --user=username --password=password --directory-prefix=/path/to/output/directory

# Where:
#    - -r means recursively
#    - --no-parent tells wget to avoid getting files from any 
#        parent directories of directory

# Note, for directories, it's important to add the trailing / to the url