1. IMPORTANT - 11/13/2015: In light of a possible breach we have scrubbed all passwords. You will need to request a password reset through the site. Click here for more information.

What is your favorite Linux script?

Discussion in 'General Linux' started by Darwin, Apr 25, 2012.

  1. Darwin

    Darwin New Member

    Apr 20, 2012
    Likes Received:
    Just being nosy today... what are your favorite scripts, tweaks or mods that you have applied to servers or your OS within Linux?

    Should be interesting for a few of us to see what you Linux Pro's are up to.
  2. KenJackson

    KenJackson Active Member

    Dec 26, 2011
    Likes Received:
    I've become rather pleased with my findls shell script.

    The Linux find command is very powerful and useful, but I found that I was typing variations of the same arcane commands a lot, so I made a script to simplify it.

    If I don't specify the directory, it uses the current directory, but I can specify one or more if I want.

    And I don't need to use the -name switch, I just list one or more filenames, with wildcards, that I want to find.

    And I don't have to use -exec grep searchtext {} + like I used to to search the files I find, I can just use -g searchtext.

    And pruning and maxdepth are supported. The order of the arguments is arbitrary. I add to it as I find additional features of find that I want to use.

    And if I don't trust my script but want to check and see what it's going to do, I just add -n and it'll show me the exact command it's going to execute when I up arrow and remove the -n.

    Cool, eh?

Share This Page