revert(3p/git): Revert merge of git upstream at v2.26.2
This causes cgit to serve error pages, which is undesirable. This reverts commit5229c9b232, reversing changes made tof2b211131f.
This commit is contained in:
parent
6f8fbf4aa4
commit
93ba78d6f4
1006 changed files with 60537 additions and 148724 deletions
82
third_party/git/git-submodule.sh
vendored
82
third_party/git/git-submodule.sh
vendored
|
|
@ -10,9 +10,8 @@ USAGE="[--quiet] [--cached]
|
|||
or: $dashless [--quiet] status [--cached] [--recursive] [--] [<path>...]
|
||||
or: $dashless [--quiet] init [--] [<path>...]
|
||||
or: $dashless [--quiet] deinit [-f|--force] (--all| [--] <path>...)
|
||||
or: $dashless [--quiet] update [--init] [--remote] [-N|--no-fetch] [-f|--force] [--checkout|--merge|--rebase] [--[no-]recommend-shallow] [--reference <repository>] [--recursive] [--[no-]single-branch] [--] [<path>...]
|
||||
or: $dashless [--quiet] update [--init] [--remote] [-N|--no-fetch] [-f|--force] [--checkout|--merge|--rebase] [--[no-]recommend-shallow] [--reference <repository>] [--recursive] [--] [<path>...]
|
||||
or: $dashless [--quiet] set-branch (--default|--branch <branch>) [--] <path>
|
||||
or: $dashless [--quiet] set-url [--] <path> <newurl>
|
||||
or: $dashless [--quiet] summary [--cached|--files] [--summary-limit <n>] [commit] [--] [<path>...]
|
||||
or: $dashless [--quiet] foreach [--recursive] <command>
|
||||
or: $dashless [--quiet] sync [--recursive] [--] [<path>...]
|
||||
|
|
@ -37,7 +36,6 @@ reference=
|
|||
cached=
|
||||
recursive=
|
||||
init=
|
||||
require_init=
|
||||
files=
|
||||
remote=
|
||||
nofetch=
|
||||
|
|
@ -47,7 +45,6 @@ custom_name=
|
|||
depth=
|
||||
progress=
|
||||
dissociate=
|
||||
single_branch=
|
||||
|
||||
die_if_unmatched ()
|
||||
{
|
||||
|
|
@ -242,15 +239,13 @@ cmd_add()
|
|||
die "$(eval_gettext "'\$sm_path' does not have a commit checked out")"
|
||||
fi
|
||||
|
||||
if test -z "$force"
|
||||
if test -z "$force" &&
|
||||
! git add --dry-run --ignore-missing --no-warn-embedded-repo "$sm_path" > /dev/null 2>&1
|
||||
then
|
||||
dryerr=$(git add --dry-run --ignore-missing --no-warn-embedded-repo "$sm_path" 2>&1 >/dev/null)
|
||||
res=$?
|
||||
if test $res -ne 0
|
||||
then
|
||||
echo >&2 "$dryerr"
|
||||
exit $res
|
||||
fi
|
||||
eval_gettextln "The following path is ignored by one of your .gitignore files:
|
||||
\$sm_path
|
||||
Use -f if you really want to add it." >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if test -n "$custom_name"
|
||||
|
|
@ -471,10 +466,6 @@ cmd_update()
|
|||
-i|--init)
|
||||
init=1
|
||||
;;
|
||||
--require-init)
|
||||
init=1
|
||||
require_init=1
|
||||
;;
|
||||
--remote)
|
||||
remote=1
|
||||
;;
|
||||
|
|
@ -529,12 +520,6 @@ cmd_update()
|
|||
--jobs=*)
|
||||
jobs=$1
|
||||
;;
|
||||
--single-branch)
|
||||
single_branch="--single-branch"
|
||||
;;
|
||||
--no-single-branch)
|
||||
single_branch="--no-single-branch"
|
||||
;;
|
||||
--)
|
||||
shift
|
||||
break
|
||||
|
|
@ -563,8 +548,6 @@ cmd_update()
|
|||
${reference:+"$reference"} \
|
||||
${dissociate:+"--dissociate"} \
|
||||
${depth:+--depth "$depth"} \
|
||||
${require_init:+--require-init} \
|
||||
$single_branch \
|
||||
$recommend_shallow \
|
||||
$jobs \
|
||||
-- \
|
||||
|
|
@ -777,55 +760,6 @@ cmd_set_branch() {
|
|||
fi
|
||||
}
|
||||
|
||||
#
|
||||
# Configures a submodule's remote url
|
||||
#
|
||||
# $@ = requested path, requested url
|
||||
#
|
||||
cmd_set_url() {
|
||||
while test $# -ne 0
|
||||
do
|
||||
case "$1" in
|
||||
-q|--quiet)
|
||||
GIT_QUIET=1
|
||||
;;
|
||||
--)
|
||||
shift
|
||||
break
|
||||
;;
|
||||
-*)
|
||||
usage
|
||||
;;
|
||||
*)
|
||||
break
|
||||
;;
|
||||
esac
|
||||
shift
|
||||
done
|
||||
|
||||
if test $# -ne 2
|
||||
then
|
||||
usage
|
||||
fi
|
||||
|
||||
# we can't use `git submodule--helper name` here because internally, it
|
||||
# hashes the path so a trailing slash could lead to an unintentional no match
|
||||
name="$(git submodule--helper list "$1" | cut -f2)"
|
||||
if test -z "$name"
|
||||
then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
url="$2"
|
||||
if test -z "$url"
|
||||
then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
git submodule--helper config submodule."$name".url "$url"
|
||||
git submodule--helper sync ${GIT_QUIET:+--quiet} "$name"
|
||||
}
|
||||
|
||||
#
|
||||
# Show commit summary for submodules in index or working tree
|
||||
#
|
||||
|
|
@ -1125,7 +1059,7 @@ cmd_absorbgitdirs()
|
|||
while test $# != 0 && test -z "$command"
|
||||
do
|
||||
case "$1" in
|
||||
add | foreach | init | deinit | update | set-branch | set-url | status | summary | sync | absorbgitdirs)
|
||||
add | foreach | init | deinit | update | set-branch | status | summary | sync | absorbgitdirs)
|
||||
command=$1
|
||||
;;
|
||||
-q|--quiet)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue