On Wed, 2013-03-20 at 11:53 -0400, Joey Hess wrote:

> I have to say, I'm fairly frightened of git-clean. I think it might
> delete large parts of my home directory. 

Ah, you're doing vcs-home stuff. I'm not so I'm not worried about it.

Perhaps an addon would be the most appropriate place to put it?

> Maybe mr clean should omit the -f, so the user has to explicitly force
> foot-shooting.

Unfortunately there is a lot of variation in the clean commands of
various VCSes, so it would need to handle that. Some commands take extra
arguments for cleaning only subtrees etc. Maybe something like this:

clean = if [ $1 = -f ] ; then shift; $vcs_clean_act "$@"; else $vcs_clean_noact 
"$@"; fi
git_clean_noact = git clean -dx --dry-run "$@"
git_clean_act = git clean -dx --force "$@"

-- 
bye,
pabs

http://wiki.debian.org/PaulWise

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to