Wednesday, March 24, 2021

Linux tricks to speed up your workday

One of the really nice things about working on the Linux command line is that you can get a lot of work done very quickly. With a handle on the most useful commands and some command-line savvy, you can take a lot of the tedium out of your daily work. This post will walk you through several handy tricks that can make your work load feel a little lighter and maybe be a little bit more enjoyable.

Emptying files with >

Any time you have an important file that you need to empty because it's become too large or the data is no longer needed, you can do that by using the command > filename. This is much faster than removing the file and recreating it with the original permissions. The > sign followed by the file name works the same as typing cat /dev/null > filename, but is wonderfully quick. It empties the file, but leaves permissions and ownership intact.

To read this article in full, please click here

Thanks to Sandra Henry-Stocker (see source)

No comments:

Post a Comment