]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Merge branch 'hw/advice-add-nothing'
authorJunio C Hamano <gitster@pobox.com>
Fri, 14 Feb 2020 20:54:19 +0000 (12:54 -0800)
committerJunio C Hamano <gitster@pobox.com>
Fri, 14 Feb 2020 20:54:19 +0000 (12:54 -0800)
Two help messages given when "git add" notices the user gave it
nothing to add have been updated to use advise() API.

* hw/advice-add-nothing:
  add: change advice config variables used by the add API
  add: use advise function to display hints

1  2 
builtin/add.c
t/t7400-submodule-basic.sh

diff --cc builtin/add.c
Simple merge
index 42a00f95b9df42362f1b8afe7eff9ca58d9d4d06,7f75bb1be62dc8dfb223e4e89ad3a2faf07bb50a..7e8925a8eed7f00b710f7efe36ccc535c92f290d
@@@ -156,9 -156,9 +156,11 @@@ test_expect_success 'submodule add to .
        (
                cd addtest-ignore &&
                cat <<-\EOF >expect &&
 -              The following path is ignored by one of your .gitignore files:
 +              The following paths are ignored by one of your .gitignore files:
                submod
-               Use -f if you really want to add them.
 -              Use -f if you really want to add it.
++              hint: Use -f if you really want to add them.
++              hint: Turn this message off by running
++              hint: "git config advice.addIgnoredFile false"
                EOF
                # Does not use test_commit due to the ignore
                echo "*" > .gitignore &&