Re: fr/vimdiff-layout (was: What's cooking in git.git (Mar 2022, #05; Wed, 23))
- From
Fernando Ramos <greenfoo@u92.eu>
- Date
- Mar 26, 2022, 22:55 UTC
- Message-ID
- <Yj+Z0T2TShqH99a/@zacax395.localdomain>
- In-Reply-To
- <220326.86k0cgk83t.gmgdl@evledraar.gmail.com>
Show 11 quoted lines
> It looks like it's emitting a new warning from the "Makefile" in > check-docs: > > $ (make clean && make check-docs) >/dev/null 2>&1; make check-docs > make -C Documentation lint-docs > make[1]: Entering directory '/home/avar/g/git/Documentation' > make[1]: Nothing to be done for 'lint-docs'. > make[1]: Leaving directory '/home/avar/g/git/Documentation' > removed but documented: git-difftool--vimdiff > removed but documented: git-mergetool--vimdiff > removed but documented: git-version
Looking at how the Makefile works it looks like this error is triggered because...
1. I have created these two new files:
- Documentation/git-difftool--vimdiff.txt
- Documentation/git-mergetool--vimdiff.txt 2. None of them are real programs (such as "git-clone") or scripts (such as
"git-mergetool--lib.sh")All the other "Documentation/*.txt" files are associated to "something" that can be executed, but not these two (they are only meant to be accessed from "git help" / "man").
Options I can think of:
A) Ignore the warning message
B) Remove these two files and add all this documentation to an already
existing one (maybe "Documentation/git-mergetool--lib.txt") C) Create a new variable in the Makefile to contain a list of "documentation
aliases" that do not correspond to a "real" command, so that they can be
filtered out when testing for documentation problems.In other to implement (C) we could do something like this:
Show 33 quoted lines
> diff --git a/Makefile b/Makefile > index 70f0a004e7..db8a1c8025 100644 > --- a/Makefile > +++ b/Makefile > @@ -597,6 +597,7 @@ TEST_BUILTINS_OBJS = > TEST_OBJS = > TEST_PROGRAMS_NEED_X = > THIRD_PARTY_SOURCES = > +DOC_ALIASES = > > # Having this variable in your environment would break pipelines because > # you cause "cd" to echo its destination to stdout. It can also take > @@ -1228,6 +1229,11 @@ THIRD_PARTY_SOURCES += compat/regex/% > THIRD_PARTY_SOURCES += sha1collisiondetection/% > THIRD_PARTY_SOURCES += sha1dc/% > > +# DOC ALIASES is a list of topics you can call "git help" on but they are no > +# real commands or scripts you can execute > +DOC_ALIASES += git-difftool--vimdiff > +DOC_ALIASES += git-mergetool--vimdiff > + > # xdiff and reftable libs may in turn depend on what is in libgit.a > GITLIBS = common-main.o $(LIB_FILE) $(XDIFF_LIB) $(REFTABLE_LIB) $(LIB_FILE) > EXTLIBS = > @@ -3355,7 +3361,7 @@ check-docs:: > -e 's/\.txt//'; \ > ) | while read how cmd; \ > do \ > - case " $(patsubst %$X,%,$(ALL_COMMANDS) $(BUILT_INS) $(EXCLUDED_PROGRAMS)) " in \ > + case " $(patsubst %$X,%,$(ALL_COMMANDS) $(BUILT_INS) $(EXCLUDED_PROGRAMS) $(DOC_ALIASES)) " in \ > *" $$cmd "*) ;; \ > *) echo "removed but $$how: $$cmd" ;; \ > esac; \
Let me know what you think. Thanks!