Using wget to recursively fetch a directory with arbitrary files in it

前端 未结 14 2109
再見小時候
再見小時候 2020-11-27 08:31

I have a web directory where I store some config files. I\'d like to use wget to pull those files down and maintain their current structure. For instance, the remote directo

14条回答
  •  悲哀的现实
    2020-11-27 09:08

    Recursive wget ignoring robots (for websites)

    wget -e robots=off -r -np --page-requisites --convert-links 'http://example.com/folder/'
    

    -e robots=off causes it to ignore robots.txt for that domain

    -r makes it recursive

    -np = no parents, so it doesn't follow links up to the parent folder

提交回复
热议问题