18.01.2020 Views

Working with Linux

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

The basic idea is to count all the lines that end with /. Here we can see we have only one directory.

Pipes are a great option to find and kill processes. Say we want to find the process ID of nautilus,

and kill all running instances. For this we use:

ps aux | grep nautilus | grep -v grep | awk '{print $2}' | xargs kill

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!