/[gentoo-x86]/eclass/git-r3.eclass
Gentoo

Diff of /eclass/git-r3.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.35 Revision 1.36
1# Copyright 1999-2014 Gentoo Foundation 1# Copyright 1999-2014 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/git-r3.eclass,v 1.35 2014/03/02 11:49:05 mgorny Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/git-r3.eclass,v 1.36 2014/03/02 11:49:49 mgorny Exp $
4 4
5# @ECLASS: git-r3.eclass 5# @ECLASS: git-r3.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# Michał Górny <mgorny@gentoo.org> 7# Michał Górny <mgorny@gentoo.org>
8# @BLURB: Eclass for fetching and unpacking git repositories. 8# @BLURB: Eclass for fetching and unpacking git repositories.
450 450
451 if [[ ${EGIT_CLONE_TYPE} == mirror ]]; then 451 if [[ ${EGIT_CLONE_TYPE} == mirror ]]; then
452 fetch_command+=( 452 fetch_command+=(
453 --prune 453 --prune
454 # mirror the remote branches as local branches 454 # mirror the remote branches as local branches
455 "refs/heads/*:refs/heads/*" 455 "+refs/heads/*:refs/heads/*"
456 # pull tags explicitly in order to prune them properly 456 # pull tags explicitly in order to prune them properly
457 "refs/tags/*:refs/tags/*" 457 "+refs/tags/*:refs/tags/*"
458 # notes in case something needs them 458 # notes in case something needs them
459 "refs/notes/*:refs/notes/*" 459 "+refs/notes/*:refs/notes/*"
460 # and HEAD in case we need the default branch 460 # and HEAD in case we need the default branch
461 # (we keep it in refs/git-r3 since otherwise --prune interferes) 461 # (we keep it in refs/git-r3 since otherwise --prune interferes)
462 HEAD:refs/git-r3/HEAD 462 "+HEAD:refs/git-r3/HEAD"
463 ) 463 )
464 else # single or shallow 464 else # single or shallow
465 local fetch_l fetch_r 465 local fetch_l fetch_r
466 466
467 if [[ ${remote_ref} == HEAD ]]; then 467 if [[ ${remote_ref} == HEAD ]]; then
500 else 500 else
501 fetch_r=${fetch_l} 501 fetch_r=${fetch_l}
502 fi 502 fi
503 503
504 fetch_command+=( 504 fetch_command+=(
505 "${fetch_l}:${fetch_r}" 505 "+${fetch_l}:${fetch_r}"
506 ) 506 )
507 fi 507 fi
508 508
509 if [[ ${EGIT_CLONE_TYPE} == shallow ]]; then 509 if [[ ${EGIT_CLONE_TYPE} == shallow ]]; then
510 # use '--depth 1' when fetching a new branch 510 # use '--depth 1' when fetching a new branch

Legend:
Removed from v.1.35  
changed lines
  Added in v.1.36

  ViewVC Help
Powered by ViewVC 1.1.20