When doing a recursive download with Wget the whole directory structure is saved, starting with the domain/hostname and then working down the directory tree inside it.
Preventing this action and downloading recursively into a directory is done using the cut dir command.
This is its syntax:
--cut-dirs=
Along with the no host parameter which is
-nH
This cuts out the hostname only from your targetted address.
If I was downloading from this address
https://website.com/folder/another/here
The files would be stored in https://website.com/folder/another/here folder structure, however using
-nH --cut-dirs=1
Would recursively download the files into /another/here
-nH --cut-dirs=2
would go into /here
Using just
-nH
Saves into /folder/another/here
A drained and empty Kennington reservoir images from a drone in early July 2024. The…
Merrimu Reservoir from drone. Click images to view larger.
Some early September spring shots from a bushwalk, It is still too early for wildflowers.
I recently needed to clone over a smaller NVMe to a 2TB SK Hynix Platinum…
If you ever needed a simple solution in Laravel to delete an entire directory and…
How to enforce only one user to register or be registered in a Laravel web…