Friday, 28 July 2017

Download a directory by wget in UNIX

Download entire directory from Nexus by wget command:

 wget -r -nH --cut-dirs=6 --no-parent --reject="index.html*"  --user=<USER> --ask-password  http://<host>:<port>/nexus/content/repositories/Test-Releases/com/edu/test/

For e.g.  In Nexus there is a folder test and inside that there are different folders with version number.

/test/1.0
/test/1.1

Below are arguments of wget commands.

-r  : Recursive
-nH : Ignore the hostname. If this parameter is not passed then it will create the folder with name of nexus host and port

--cut-dirs : Ignore the number of directories post Nexus host and port. If 5 is passed in this case then in local directories will be like edu/test/*

--reject="index.html*" : Download the actual content but not the index.html

--ask-password  : It will ask for password after running command

No comments:

Post a Comment

Thank You for your valuable comment

Difference between class level and object locking and static object lock

1) Class level locking will lock entire class, so no other thread can access any of other synchronized blocks. 2) Object locking will lo...