Skip to content

Instantly share code, notes, and snippets.

@tmiele
Created August 4, 2014 16:28
Show Gist options
  • Save tmiele/da851765be6d4f08b3f5 to your computer and use it in GitHub Desktop.
Save tmiele/da851765be6d4f08b3f5 to your computer and use it in GitHub Desktop.
epitech-clean-script
#!/bin/sh -e
clean()
{
rm -rfv $1/.*~
rm -rfv $1/*~
rm -rfv $1/*.default
rm -rfv $1/*.sample
}
if [ $1 ]
then
if [ -d $1 ]
then
clean $1
else
echo "$1 not a directory"
fi
else
clean `pwd`
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment