Created
April 8, 2012 03:11
-
-
Save wlaurance/2334202 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/bash | |
rm `find |grep "~"$` | |
If it says, "rm: missing operand Try rm --help' for more information."
, then you have no files from your pwd
that end in a ~
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The $ at the end ensures that it will only match a ~ at the end of the word, that way if you have files with a ~ anywhere but the end will not be deleted.