+
These features will be removed.
+* Support for "--stdin" option in the "name-rev" command was
+ deprecated (and hidden from the documentation) in the Git 2.40
+ timeframe, in preference to its synonym "--annotate-stdin". Git 3.0
+ removes the support for "--stdin" altogether.
+
+ * The git-whatchanged(1) command has outlived its usefulness more than
+ 10 years ago, and takes more keystrokes to type than its rough
+ equivalent `git log --raw`. We have nominated the command for
+ removal, have changed the command to refuse to work unless the
+ `--i-still-use-this` option is given, and asked the users to report
+ when they do so. So far there hasn't been a single complaint.
+ +
+ The command will be removed.
== Superseded features that will not be deprecated
awk "/^manpages = {$$/ {flag=1 ; next } /^}$$/ { flag=0 } flag { gsub(/^ \047/, \"\"); gsub(/\047 : [157],\$$/, \"\"); print }" meson.build | \
grep -v -e '#' -e '^$$' | \
sort >tmp-meson-diff/meson.adoc && \
- ls git*.adoc scalar.adoc | grep -v -e git-bisect-lk2009.adoc -e git-pack-redundant.adoc -e git-tools.adoc >tmp-meson-diff/actual.adoc && \
- ls git*.adoc scalar.adoc | grep -v -e git-bisect-lk2009.adoc -e git-tools.adoc >tmp-meson-diff/actual.adoc && \
++ ls git*.adoc scalar.adoc | \
++ grep -v -e git-bisect-lk2009.adoc \
++ -e git-pack-redundant.adoc \
++ -e git-tools.adoc \
++ -e git-whatchanged.adoc \
++ >tmp-meson-diff/actual.adoc && \
if ! cmp tmp-meson-diff/meson.adoc tmp-meson-diff/actual.adoc; then \
echo "Meson man pages differ from actual man pages:"; \
diff -u tmp-meson-diff/meson.adoc tmp-meson-diff/actual.adoc; \
}
----
- Also add the relevant line in `builtin.h` near `cmd_whatchanged()`:
+ Also add the relevant line in `builtin.h` near `cmd_version()`:
----
-int cmd_walken(int argc, const char **argv, const char *prefix);
+int cmd_walken(int argc, const char **argv, const char *prefix, struct repository *repo);
----
- Include the command in `git.c` in `commands[]` near the entry for `whatchanged`,
+ Include the command in `git.c` in `commands[]` near the entry for `version`,
maintaining alphabetical ordering:
----
'git-verify-tag.adoc' : 1,
'git-version.adoc' : 1,
'git-web--browse.adoc' : 1,
-- 'git-whatchanged.adoc' : 1,
'git-worktree.adoc' : 1,
'git-write-tree.adoc' : 1,
'git.adoc' : 1,
'gitworkflows.adoc' : 7,
}
+manpages_breaking_changes = {
+ 'git-pack-redundant.adoc' : 1,
++ 'git-whatchanged.adoc' : 1,
+}
+
+if not get_option('breaking_changes')
+ manpages += manpages_breaking_changes
+endif
+
docs_backend = get_option('docs_backend')
if docs_backend == 'auto'
- if find_program('asciidoc', dirs: program_path, required: false).found()
+ if find_program('asciidoc', dirs: program_path, native: true, required: false).found()
docs_backend = 'asciidoc'
- elif find_program('asciidoctor', dirs: program_path, required: false).found()
+ elif find_program('asciidoctor', dirs: program_path, native: true, required: false).found()
docs_backend = 'asciidoctor'
else
error('Neither asciidoc nor asciidoctor were found.')
expect="$TEST_DIRECTORY/t4013/diff.$test"
actual="$pfx-diff.$test"
- test_expect_success "git $cmd # magic is ${magic:-(not used)}" '
+ case "$cmd" in
+ whatchanged | whatchanged" "*)
- prereq=WITHOUT_BREAKING_CHANGES
++ prereq=!WITH_BREAKING_CHANGES
+ ;;
+ *)
+ prereq=;;
+ esac
+
+ test_expect_success $prereq "git $cmd # magic is ${magic:-(not used)}" '
{
echo "$ git $cmd"
+
+ case "$cmd" in
+ whatchanged | whatchanged" "*)
+ run="whatchanged --i-still-use-this"
+ run="$run ${cmd#whatchanged}" ;;
+ *)
+ run=$cmd ;;
+ esac &&
case "$magic" in
"")
- GIT_PRINT_SHA1_ELLIPSIS=yes git $cmd ;;
+ GIT_PRINT_SHA1_ELLIPSIS=yes git $run ;;
noellipses)
- git $cmd ;;
+ git $run ;;
esac |
sed -e "s/^\\(-*\\)$V\\(-*\\)\$/\\1g-i-t--v-e-r-s-i-o-n\2/" \
-e "s/^\\(.*mixed; boundary=\"-*\\)$V\\(-*\\)\"\$/\\1g-i-t--v-e-r-s-i-o-n\2\"/"
diff-tree -R --stat --compact-summary initial mode
EOF
-test_expect_success WITHOUT_BREAKING_CHANGES 'whatchanged needs --i-still-use-this' '
++test_expect_success !WITH_BREAKING_CHANGES 'whatchanged needs --i-still-use-this' '
+ test_must_fail git whatchanged >message 2>&1 &&
+ test_grep "nominated for removal" message
+ '
+
test_expect_success 'log -m matches pure log' '
git log master >result &&
process_diffs result >expected &&
)
'
- for cmd in show whatchanged reflog format-patch
+ cmds="show reflog format-patch"
-if test_have_prereq WITHOUT_BREAKING_CHANGES
++if test_have_prereq !WITH_BREAKING_CHANGES
+ then
+ cmds="$cmds whatchanged"
+ fi
+ for cmd in $cmds
do
case "$cmd" in
format-patch) myarg="HEAD~.." ;;
test_cmp expect actual
'
- test_expect_success 'whatchanged is expected format' '
-test_expect_success WITHOUT_BREAKING_CHANGES 'whatchanged is expected format' '
++test_expect_success !WITH_BREAKING_CHANGES 'whatchanged is expected format' '
+ whatchanged="whatchanged --i-still-use-this" &&
git log --no-merges --raw >expect &&
- git whatchanged >actual &&
+ git $whatchanged >actual &&
test_cmp expect actual
'
git log --pretty=raw >expect.log.raw &&
git reflog --abbrev-commit >expect.reflog.abbrev &&
git reflog --no-abbrev-commit >expect.reflog.full &&
- git whatchanged --abbrev-commit >expect.whatchanged.abbrev &&
- git whatchanged --no-abbrev-commit >expect.whatchanged.full &&
+
- if test_have_prereq WITHOUT_BREAKING_CHANGES
++ if test_have_prereq !WITH_BREAKING_CHANGES
+ then
+ git $whatchanged --abbrev-commit >expect.whatchanged.abbrev &&
+ git $whatchanged --no-abbrev-commit >expect.whatchanged.full
+ fi &&
test_config log.abbrevCommit true &&
git reflog --no-abbrev-commit >actual &&
test_cmp expect.reflog.full actual &&
- git whatchanged >actual &&
- test_cmp expect.whatchanged.abbrev actual &&
- git whatchanged --no-abbrev-commit >actual &&
- test_cmp expect.whatchanged.full actual
- if test_have_prereq WITHOUT_BREAKING_CHANGES
++ if test_have_prereq !WITH_BREAKING_CHANGES
+ then
+ git $whatchanged >actual &&
+ test_cmp expect.whatchanged.abbrev actual &&
+ git $whatchanged --no-abbrev-commit >actual &&
+ test_cmp expect.whatchanged.full actual
+ fi
'
test_expect_success '--abbrev-commit with core.abbrev=false' '