Simple find

find / -name '*android*' 2>errors.txt
Just search the root of the file hierarchy for matches for a text string. Send errors to a file rather than stdout.

0
By: peter4512
2012-01-11 15:16:58

These Might Interest You

  • Replaces "650" with "999" in simple.xml. xml used - http://www.w3schools.com/xml/simple.xml


    1
    xmlstarlet ed -u '//food[calories="650"]/calories' -v "999" simple.xml
    zlemini · 2016-10-05 18:29:01 0
  • Splits the input based on commas and prints it in a nice column format. This would not work for CSV rows that have "," between quotes or with newline characters. Use only simple simple csv files. Show Sample Output


    18
    column -s, -t <tmp.csv
    pykler · 2009-09-24 20:57:32 0
  • This inserts an element as last child under /breakfast_menu/food in simple.xml. xml used - http://www.w3schools.com/xml/simple.xml Show Sample Output


    5
    xmlstarlet ed -s "/breakfast_menu/food" -t elem -n 'foo' -v "bar" simple.xml
    zlemini · 2012-06-03 18:35:53 0
  • Thanks to comment if that works or not... If you have already typed that snippet or you know you already have IO::Interface::Simple perl module, you can type only the last command : perl -e 'use IO::Interface::Simple; my $ip=IO::Interface::Simple->new($ARGV[0]); print $ip->address,$/;' <INTERFACE> ( The first perl command will install the module if it's not there already... )


    1
    x=IO::Interface::Simple; perl -e 'use '$x';' &>/dev/null || cpan -i "$x"; perl -e 'use '$x'; my $ip='$x'->new($ARGV[0]); print $ip->address,$/;' <INTERFACE>
    sputnick · 2009-12-13 02:23:40 6

What do you think?

Any thoughts on this command? Does it work on your machine? Can you do the same thing with only 14 characters?

You must be signed in to comment.

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands



Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: