Cecil's Log of Digital Life

Wednesday, May 30, 2012

Useful Unix Command Line Script

Find Dead Symbolic Links in The Whole System
find / -type l ! -exec test -r {} \; -print

Find And Replace Text Recursively
find . -type f -print0 | xargs -0 -n32 -P6 sed -i 's/AAA/BBB/g'

Search Text Recursively
find . -type f -print0 | xargs -0 -n32 -P6 grep -iH "ttt"

List The Size of Current Directory
du -sk *
Posted by Unknown at 11:39 AM
Email ThisBlogThis!Share to XShare to FacebookShare to Pinterest
Labels: Linux

No comments:

Post a Comment

Newer Post Older Post Home

About Me

Unknown
View my complete profile

Popular Posts

  • 什麼是CGI、FastCGI、PHP-CGI、PHP-FPM、Spawn-FCGI?

Labels

Windows Linux Network Macintosh Academia Java Matlab Office GPS Game Powerpoint X-Window Benchmark Bluetooth CGI Evernote Excel Garmin Onenote Outlook PHP Ranking Samsung i617 Skype Sound Storage Tablet Thinkpad Video Web Server Webcam Word microSD

Blog Archive

  • ►  2014 (2)
    • ►  March (2)
  • ►  2013 (2)
    • ►  July (1)
    • ►  March (1)
  • ▼  2012 (11)
    • ►  October (2)
    • ►  August (2)
    • ►  June (1)
    • ▼  May (2)
      • Useful Mac OS Command Line Script
      • Useful Unix Command Line Script
    • ►  March (4)
  • ►  2011 (15)
    • ►  November (4)
    • ►  September (5)
    • ►  April (3)
    • ►  March (3)
  • ►  2010 (34)
    • ►  December (3)
    • ►  October (2)
    • ►  September (2)
    • ►  August (4)
    • ►  July (2)
    • ►  June (2)
    • ►  May (1)
    • ►  April (5)
    • ►  March (4)
    • ►  February (8)
    • ►  January (1)
  • ►  2009 (2)
    • ►  December (2)
Simple theme. Powered by Blogger.