check-docs: fix for setups where executables have an extension
authorJohannes Schindelin <johannes.schindelin@gmx.de>
Mon, 25 Mar 2019 21:41:39 +0000 (14:41 -0700)
committerJunio C Hamano <gitster@pobox.com>
Mon, 1 Apr 2019 05:01:11 +0000 (14:01 +0900)
On Windows, for example, executables (must) have the extension `.exe`.
Our `check-docs` target was not prepared for that.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Makefile
index 02a29dfb5719d4719a274896a5c6a3285a333eca..8654c130f87c054719a6f3f0c25c1ac9e0acd7eb 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -3057,7 +3057,7 @@ ALL_COMMANDS += git-gui git-citool
 .PHONY: check-docs
 check-docs::
        $(MAKE) -C Documentation lint-docs
-       @(for v in $(ALL_COMMANDS); \
+       @(for v in $(patsubst %$X,%,$(ALL_COMMANDS)); \
        do \
                case "$$v" in \
                git-merge-octopus | git-merge-ours | git-merge-recursive | \
@@ -3087,7 +3087,7 @@ check-docs::
                    -e 's/\.txt//'; \
        ) | while read how cmd; \
        do \
-               case " $(ALL_COMMANDS) " in \
+               case " $(patsubst %$X,%,$(ALL_COMMANDS)) " in \
                *" $$cmd "*)    ;; \
                *) echo "removed but $$how: $$cmd" ;; \
                esac; \