DEV Community

Discussion on: 6 Unix tools you need to know about

Collapse
 
_garybell profile image
Gary Bell

I'm a huge fan of the (relatively) straight forward find command. When coupled with -exec, you can do some pretty creative things, fairly quickly.

I've used find historically for getting backup files which are more than 2 weeks old, and deleting them. It's a simple way of keeping backups from taking over hard drive space, without needing to do everything manually

Collapse
 
geekypandey profile image
Anurag Pandey

That coupling with exec takes it to another level. What are your other favourites?

Collapse
 
_garybell profile image
Gary Bell

Going to be boring and say grep. I think a lot of people have it as a go-to tool to filter the returned output of a command into something useful.

I don't spend a lot of time in the terminal using Linux/Unix specific commands. Most of my time on the terminal is spend using Git, and increasingly more often, redis-cli

Thread Thread
 
geekypandey profile image
Anurag Pandey

Yeah. git grep is super handy to find files with particular snippets of code.

I started with competitive programming recently and I used to save code as filename.py and then testcase_filename for the testcases. ls | grep -v testcase came in handy to code files and clear the noise.