tj.git-extras/bin/git-clear-soft
Matiss 61fee79cc7 Add git-clear-soft command
Modify git-clear to indicate default behavior of removing git ignored files
2016-05-01 19:05:21 +02:00

8 lines
231 B
Bash
Executable file

#!/usr/bin/env bash
echo "Sure? - This command may delete files that cannot be recovered. Files and directories in .gitignore will be preserved [Y/n]"
read ans
if [ "$ans" != "n" ]
then git clean -d -f && git reset --hard
fi