Linux commands collection

For web development, as rule, we use LAMP stack and multiple commands. At here I collected and will collected continue most popular commands for work in Linux environment.

Helpful Linux commands for web development

Secure connect to remote server via SSH, SFTP

ssh user_name@host_name -p number_port

sftp user_name@host_name -oPort=number_port

Move folder from localhost to remote server via SSH

scp -r /opt/lampp/htdocs/project-name/wp-content/uploads user_name@host-name.com:/home/user_name/project_name/wp-content/

Move folder from remote server to localhost via SSH

scp -r user_name@host-name:/home/user_name/project_name/wp-content/uploads/ /opt/lampp/htdocs/project-name/wp-content/

Move file from localhost to remote server via SSH

scp user_name@host-name:/home/user_name/project_name/wp-config.php /opt/lampp/htdocs/project-name/

Create Zip archive catologue to current directory

zip -r archive.zip catalogue_name 

Extract Zip archive to current directory

unzip archive.zip

Extract Zip File to Specific or Different Directory

unzip archive.zip -d /tmp/unziped

… to be continue

Leave Comment

Your email address will not be published. Required fields are marked *