bash terminal execute multiple commands in one line

http://askubuntu.com/questions/334994/which-one-is-better-using-or-to-execute-multiple-commands-in-one-line

A; B    Run A and then B, regardless of success of A
A && B  Run B if A succeeded
A || B  Run B if A failed
A &     Run A in background.
Advertisements

How to update slimerjs to 0.10 or newer which is installed via npm install slimerjs ?

If you came across this issue like me here is how to update slimerjs:

npm install -g slimerjs
cd /usr/local/lib/node_modules/slimerjs/lib/
mv slimer slimerjs-bak
wget http://download.slimerjs.org/releases/0.10.0/slimerjs-0.10.0.zip
unzip slimerjs-0.10.0.zip
mv slimerjs-0.10.0/ slimer

with new v10.0 you need to update your firefox version too. you can choose a version between 42 and 46.

How to compress files while using linux terminal with tar via ssh ?

You can use tar:

“tar -zcvf archive.tar.gz folder/”

-z: Compress with gzip

-c: Create archive

-v: Display progress

-f: filename

For extracting archive:
“tar -zxvf archive.tar.gz -C /extractionpoint”

 

For more detailed info:

-C Directory Causes the tar command to perform a chdir subroutine to the directory specified by the Directory variable. Using the -C flag allows multiple directories not related by a close common parent to be archived, using short relative path names. For example, to archive files from the /usr/include and /etc directories, you might use the following command:

tar -C