Merge pull request #603 from richardfearn/git-clear-consistent-defaults

git-clear-soft: change default yes/no option to "no" (as with git-clear)
This commit is contained in:
hemanth.hm 2016-11-20 05:16:22 +05:30 committed by GitHub
commit 29a5596d9e

View file

@ -1,7 +1,7 @@
#!/usr/bin/env bash
echo -n "Sure? - This command may delete files that cannot be recovered. Files and directories in .gitignore will be preserved [Y/n]: "
echo -n "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" ]
if [ "$ans" == "y" ]
then git clean -d -f && git reset --hard
fi