path: root/Makefile
diff options
authorErik Faye-Lund <>2010-11-26 16:00:39 (GMT)
committerJunio C Hamano <>2010-12-05 20:15:12 (GMT)
commit6612b9e471a3e25079dac5257ead8cf6abe68575 (patch)
tree16dd87d66b5f169af3f33f0d0fedb003ae2d5789 /Makefile
parent7d43de925b2771d295d8fc4341b7bd544e2a74fa (diff)
help: always suggest common-cmds if prefix of cmd
If someone runs "git st", the command "git status" is not suggested because it's not one of the closest levenshtein-neighbour. Reserve the distance of 0 for common commands where the entered command is a prefixe, as these are often more likely to be what the user meant. This way, "git status" is the first suggestion, while a list of possible typos are still suggested as well. Signed-off-by: Erik Faye-Lund <> Signed-off-by: Junio C Hamano <>
Diffstat (limited to 'Makefile')
1 files changed, 2 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 919ed2b..7baa621 100644
--- a/Makefile
+++ b/Makefile
@@ -1620,6 +1620,8 @@ git$X: git.o $(BUILTIN_OBJS) $(GITLIBS)
$(QUIET_LINK)$(CC) $(ALL_CFLAGS) -o $@ git.o \
+help.o: common-cmds.h
builtin/help.o: common-cmds.h
builtin/help.s builtin/help.o: EXTRA_CPPFLAGS = \
'-DGIT_HTML_PATH="$(htmldir_SQ)"' \