aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorShawn Bohrer <shawn.bohrer@gmail.com>2007-11-11 19:48:47 -0600
committerJunio C Hamano <gitster@pobox.com>2007-11-18 19:11:42 -0800
commit113f10f22f4b3b599e44e192e241e0bace9cc39e (patch)
tree83fdfa4897870cb07cea1ea4b8afa129e0c50e34 /Makefile
parentea55960518bb104020c02aa2f64b33f93d1775e7 (diff)
downloadgit-113f10f22f4b3b599e44e192e241e0bace9cc39e.tar.gz
git-113f10f22f4b3b599e44e192e241e0bace9cc39e.tar.xz
Make git-clean a builtin
This replaces git-clean.sh with builtin-clean.c, and moves git-clean.sh to the examples. This also introduces a change in behavior when removing directories explicitly specified as a path. For example currently: 1. When dir has only untracked files, these two behave differently: $ git clean -n dir $ git clean -n dir/ the former says "Would not remove dir/", while the latter would say "Would remove dir/untracked" for all paths under it, but not the directory itself. With -d, the former would stop refusing, however since the user explicitly asked to remove the directory the -d is no longer required. 2. When there are more parameters: $ git clean -n dir foo $ git clean -n dir/ foo both cases refuse to remove dir/ unless -d is specified. Once again since both cases requested to remove dir the -d is no longer required. Thanks to Johannes Schindelin for the conversion to using the parse-options API. Signed-off-by: Shawn Bohrer <shawn.bohrer@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile3
1 files changed, 2 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index cabde8177..87da99f43 100644
--- a/Makefile
+++ b/Makefile
@@ -213,7 +213,7 @@ BASIC_LDFLAGS =
SCRIPT_SH = \
git-bisect.sh git-checkout.sh \
- git-clean.sh git-clone.sh git-commit.sh \
+ git-clone.sh git-commit.sh \
git-ls-remote.sh \
git-merge-one-file.sh git-mergetool.sh git-parse-remote.sh \
git-pull.sh git-rebase.sh git-rebase--interactive.sh \
@@ -330,6 +330,7 @@ BUILTIN_OBJS = \
builtin-check-attr.o \
builtin-checkout-index.o \
builtin-check-ref-format.o \
+ builtin-clean.o \
builtin-commit-tree.o \
builtin-count-objects.o \
builtin-describe.o \