Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 255451 | Differences between
and this patch

Collapse All | Expand All

(-)/usr/portage/eclass/git.eclass (-2 / +8 lines)
Lines 40-46 Link Here
40
40
41
## -- EGIT_FETCH_CMD:  git clone command
41
## -- EGIT_FETCH_CMD:  git clone command
42
#
42
#
43
EGIT_FETCH_CMD="git clone --bare --depth 1"
43
EGIT_FETCH_CMD="git clone --bare"
44
44
45
## -- EGIT_UPDATE_CMD:  git fetch command
45
## -- EGIT_UPDATE_CMD:  git fetch command
46
#
46
#
Lines 189-194 Link Here
189
	[[ -z ${EGIT_REPO_URI##*/} ]] && EGIT_REPO_URI="${EGIT_REPO_URI%/}"
189
	[[ -z ${EGIT_REPO_URI##*/} ]] && EGIT_REPO_URI="${EGIT_REPO_URI%/}"
190
	EGIT_CLONE_DIR="${EGIT_PROJECT}"
190
	EGIT_CLONE_DIR="${EGIT_PROJECT}"
191
191
192
	# determine whether to perform shallow clone
193
	local EGIT_FETCH_OPTS
194
	if [[ ${EGIT_BRANCH} = ${EGIT_TREE} ]] && [[ ${EGIT_BRANCH} = master ]] ; then
195
		EGIT_FETCH_OPTS="--depth 1"
196
	fi
197
192
	debug-print "${FUNCNAME}: EGIT_OPTIONS = \"${EGIT_OPTIONS}\""
198
	debug-print "${FUNCNAME}: EGIT_OPTIONS = \"${EGIT_OPTIONS}\""
193
199
194
	export GIT_DIR="${EGIT_STORE_DIR}/${EGIT_CLONE_DIR}"
200
	export GIT_DIR="${EGIT_STORE_DIR}/${EGIT_CLONE_DIR}"
Lines 198-204 Link Here
198
		einfo "git clone start -->"
204
		einfo "git clone start -->"
199
		einfo "   repository: ${EGIT_REPO_URI}"
205
		einfo "   repository: ${EGIT_REPO_URI}"
200
206
201
		${EGIT_FETCH_CMD} ${EGIT_OPTIONS} "${EGIT_REPO_URI}" ${EGIT_PROJECT} \
207
		${EGIT_FETCH_CMD} ${EGIT_FETCH_OPTS} ${EGIT_OPTIONS} "${EGIT_REPO_URI}" ${EGIT_PROJECT} \
202
			|| die "${EGIT}: can't fetch from ${EGIT_REPO_URI}."
208
			|| die "${EGIT}: can't fetch from ${EGIT_REPO_URI}."
203
209
204
		# We use --bare cloning, so git doesn't do this for us.
210
		# We use --bare cloning, so git doesn't do this for us.

Return to bug 255451