Add something new to Virb:

Virb

Are you sure you want to delete that?

or Cancel

 

Posted on Feb 14, 2007

This should be way easier

So for whatever reason, there is no standard sleep command in unix that will sleep for less than a second. I guess some distributions have usleep (microsleep) which is great if your system has it or if what your writing is just for your system. But anyways...say you want to delete a bunch of files without locking up your machine...

ls -al ~/oldFiles | perl -lne "unlink; select(undef,undef,undef,.05);"

Where .05 would be 50ms.

Special thanks to perl and google.

Loading comments...

Likes

Details

Viewed 250 times

© 2007 Matt

virb.com/t/906
tweet!

Flag this text post!

Flag this text post as:

or Cancel

 

Advertisement

Flag this profile!

Flag this profile as:

or Cancel