Merge branch 'maint'
* maint: Documentation: cloning to empty directory is allowed Clarify kind of conflict in merge-one-file helper git config: clarify --add and --get-color archive-tar.c: squelch a type mismatch warning
This commit is contained in:
commit
6345d7a0d1
@ -149,7 +149,7 @@ then the cloned repository will become corrupt.
|
||||
part of the source repository is used if no directory is
|
||||
explicitly given ("repo" for "/path/to/repo.git" and "foo"
|
||||
for "host.xz:foo/.git"). Cloning into an existing directory
|
||||
is not allowed.
|
||||
is only allowed if the directory is empty.
|
||||
|
||||
:git-clone: 1
|
||||
include::urls.txt[]
|
||||
|
@ -69,7 +69,8 @@ OPTIONS
|
||||
|
||||
--add::
|
||||
Adds a new line to the option without altering any existing
|
||||
values. This is the same as providing '^$' as the value_regex.
|
||||
values. This is the same as providing '^$' as the value_regex
|
||||
in `--replace-all`.
|
||||
|
||||
--get::
|
||||
Get the value for a given key (optionally filtered by a regex
|
||||
@ -155,7 +156,7 @@ See also <<FILES>>.
|
||||
When the color setting for `name` is undefined, the command uses
|
||||
`color.ui` as fallback.
|
||||
|
||||
--get-color name default::
|
||||
--get-color name [default]::
|
||||
|
||||
Find the color configured for `name` (e.g. `color.diff.new`) and
|
||||
output it as the ANSI color escape sequence to the standard
|
||||
|
@ -180,7 +180,7 @@ static int write_tar_entry(struct archiver_args *args,
|
||||
|
||||
sprintf(header.mode, "%07o", mode & 07777);
|
||||
sprintf(header.size, "%011lo", S_ISREG(mode) ? size : 0);
|
||||
sprintf(header.mtime, "%011lo", args->time);
|
||||
sprintf(header.mtime, "%011lo", (unsigned long) args->time);
|
||||
|
||||
sprintf(header.uid, "%07o", 0);
|
||||
sprintf(header.gid, "%07o", 0);
|
||||
|
@ -113,6 +113,10 @@ case "${1:-.}${2:-.}${3:-.}" in
|
||||
src1=`git-unpack-file $2`
|
||||
git merge-file "$src1" "$orig" "$src2"
|
||||
ret=$?
|
||||
msg=
|
||||
if [ $ret -ne 0 ]; then
|
||||
msg='content conflict'
|
||||
fi
|
||||
|
||||
# Create the working tree file, using "our tree" version from the
|
||||
# index, and then store the result of the merge.
|
||||
@ -120,7 +124,10 @@ case "${1:-.}${2:-.}${3:-.}" in
|
||||
rm -f -- "$orig" "$src1" "$src2"
|
||||
|
||||
if [ "$6" != "$7" ]; then
|
||||
echo "ERROR: Permissions conflict: $5->$6,$7."
|
||||
if [ -n "$msg" ]; then
|
||||
msg="$msg, "
|
||||
fi
|
||||
msg="${msg}permissions conflict: $5->$6,$7"
|
||||
ret=1
|
||||
fi
|
||||
if [ "$1" = '' ]; then
|
||||
@ -128,7 +135,7 @@ case "${1:-.}${2:-.}${3:-.}" in
|
||||
fi
|
||||
|
||||
if [ $ret -ne 0 ]; then
|
||||
echo "ERROR: Merge conflict in $4"
|
||||
echo "ERROR: $msg in $4"
|
||||
exit 1
|
||||
fi
|
||||
exec git update-index -- "$4"
|
||||
|
Loading…
Reference in New Issue
Block a user