All command of SSH(Secure Shell) operations.
1.1 zip all files in the current directory
zip filename.zip *
Note: In this, subfolders and files will note includes and you can add file name without extension
1.2 zip-up an entire directory including all sub-directories
e.g zip -r filename *
zip -r backup *
1.3 zip-up an specificfolderincluding all sub-directories
e.g zip -r <output_file> <folder_1> <folder_2> ... <folder_n>
zip -r backup.zip Documents
2.1 Unzip specific file
e.g unzip filename.zip
unzip backup.zip
For this, we will use SCP command and need both Servers IP Address, Username, Password and path to file or folder
3.1 Move file from the old server (A) to a new server (B) while logged into A
e.g scp path/to/file UsernameofB@IPofB:path/to/destination
scp public_html/filename.zip yuvrajkhavad@192.111.1.1:public_html/newdata
Note:
public_html/filename.zip: Server A Details
yuvrajkhavad@192.111.1.1:public_html/newdata: Server B Details
4.1 Delete full folder
e.g rm -rf foldername/
Pull requests are welcome. Please add your ssh command submit pull
Please make sure to update tests as appropriate.