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

Diff of /eclass/git.eclass

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

Revision 1.13 Revision 1.14
1# Copyright 1999-2006 Gentoo Foundation 1# Copyright 1999-2006 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/Attic/git.eclass,v 1.13 2008/06/16 07:51:00 zlin Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/Attic/git.eclass,v 1.14 2008/06/16 11:22:38 zlin Exp $
4 4
5## --------------------------------------------------------------------------- # 5## --------------------------------------------------------------------------- #
6# subversion.eclass author: Akinori Hattori <hattya@gentoo.org> 6# subversion.eclass author: Akinori Hattori <hattya@gentoo.org>
7# modified for git by Donnie Berkholz <spyderous@gentoo.org> 7# modified for git by Donnie Berkholz <spyderous@gentoo.org>
8# improved by Fernando J. Pereda <ferdy@gentoo.org> 8# improved by Fernando J. Pereda <ferdy@gentoo.org>
188 [[ -z ${EGIT_REPO_URI##*/} ]] && EGIT_REPO_URI="${EGIT_REPO_URI%/}" 188 [[ -z ${EGIT_REPO_URI##*/} ]] && EGIT_REPO_URI="${EGIT_REPO_URI%/}"
189 EGIT_CLONE_DIR="${EGIT_PROJECT}" 189 EGIT_CLONE_DIR="${EGIT_PROJECT}"
190 190
191 debug-print "${FUNCNAME}: EGIT_OPTIONS = \"${EGIT_OPTIONS}\"" 191 debug-print "${FUNCNAME}: EGIT_OPTIONS = \"${EGIT_OPTIONS}\""
192 192
193 mkdir -p "${S}"
194 export GIT_DIR="${EGIT_STORE_DIR}/${EGIT_CLONE_DIR}" 193 export GIT_DIR="${EGIT_STORE_DIR}/${EGIT_CLONE_DIR}"
195 export GIT_WORK_TREE="${S}"
196 194
197 if [[ ! -d ${EGIT_CLONE_DIR} ]] ; then 195 if [[ ! -d ${EGIT_CLONE_DIR} ]] ; then
198 # first clone 196 # first clone
199 einfo "git clone start -->" 197 einfo "git clone start -->"
200 einfo " repository: ${EGIT_REPO_URI}" 198 einfo " repository: ${EGIT_REPO_URI}"
235 fi 233 fi
236 234
237 einfo " committish: ${EGIT_TREE}" 235 einfo " committish: ${EGIT_TREE}"
238 236
239 # export to the ${WORKDIR} 237 # export to the ${WORKDIR}
240 git checkout -f ${EGIT_TREE} 238 mkdir -p "${S}"
239 git archive --format=tar ${EGIT_TREE} | ( cd "${S}" ; tar xf - )
241 240
242 echo ">>> Unpacked to ${S}" 241 echo ">>> Unpacked to ${S}"
243 242
244} 243}
245 244

Legend:
Removed from v.1.13  
changed lines
  Added in v.1.14

  ViewVC Help
Powered by ViewVC 1.1.20