Skip to content

Commit dcbf041

Browse files
committed
Merge branch 'maint-1.6.0' into maint-1.6.1
* maint-1.6.0: Fix bash completion in path with spaces bash completion: only show 'log --merge' if merging git-tag(1): add hint about commit messages Documentation: update graph api example.
2 parents 8e4f767 + ba7906f commit dcbf041

File tree

3 files changed

+12
-6
lines changed

3 files changed

+12
-6
lines changed

Documentation/git-tag.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ OPTIONS
6363
are printed when using -l.
6464
The default is not to print any annotation lines.
6565
If no number is given to `-n`, only the first line is printed.
66+
If the tag is not annotated, the commit message is displayed instead.
6667

6768
-l <pattern>::
6869
List tags with names that match the given pattern (or all if no pattern is given).

Documentation/technical/api-history-graph.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -148,22 +148,22 @@ outputting that information, if desired.
148148
------------
149149
*
150150
*
151-
M
151+
*
152152
|\
153153
* |
154154
| | *
155155
| \ \
156156
| \ \
157-
M-. \ \
157+
*-. \ \
158158
|\ \ \ \
159159
| | * | |
160160
| | | | | *
161161
| | | | | *
162-
| | | | | M
162+
| | | | | *
163163
| | | | | |\
164164
| | | | | | *
165165
| * | | | | |
166-
| | | | | M \
166+
| | | | | * \
167167
| | | | | |\ |
168168
| | | | * | | |
169169
| | | | * | | |

contrib/completion/git-completion.bash

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -935,6 +935,11 @@ _git_log ()
935935
__git_has_doubledash && return
936936

937937
local cur="${COMP_WORDS[COMP_CWORD]}"
938+
local g="$(git rev-parse --git-dir 2>/dev/null)"
939+
local merge=""
940+
if [ -f "$g/MERGE_HEAD" ]; then
941+
merge="--merge"
942+
fi
938943
case "$cur" in
939944
--pretty=*)
940945
__gitcomp "
@@ -966,7 +971,7 @@ _git_log ()
966971
--decorate --diff-filter=
967972
--color-words --walk-reflogs
968973
--parents --children --full-history
969-
--merge
974+
$merge
970975
"
971976
return
972977
;;
@@ -1751,7 +1756,7 @@ _gitk ()
17511756
local cur="${COMP_WORDS[COMP_CWORD]}"
17521757
local g="$(git rev-parse --git-dir 2>/dev/null)"
17531758
local merge=""
1754-
if [ -f $g/MERGE_HEAD ]; then
1759+
if [ -f "$g/MERGE_HEAD" ]; then
17551760
merge="--merge"
17561761
fi
17571762
case "$cur" in

0 commit comments

Comments
 (0)