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

Diff of /eclass/bzr.eclass

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

Revision 1.3 Revision 1.4
1# Copyright 1999-2009 Gentoo Foundation 1# Copyright 1999-2009 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/bzr.eclass,v 1.3 2009/08/04 20:18:23 fauli Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/bzr.eclass,v 1.4 2009/09/24 07:19:41 fauli Exp $
4# 4#
5# @ECLASS: bzr.eclass 5# @ECLASS: bzr.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# Jorge Manuel B. S. Vicetto <jmbsvicetto@gentoo.org>, 7# Jorge Manuel B. S. Vicetto <jmbsvicetto@gentoo.org>,
8# Ulrich Mueller <ulm@gentoo.org>, 8# Ulrich Mueller <ulm@gentoo.org>,
112# EBZR_STORE_DIR. 112# EBZR_STORE_DIR.
113# 113#
114# default: ${PN} 114# default: ${PN}
115EBZR_CACHE_DIR="${EBZR_CACHE_DIR:-${PN}}" 115EBZR_CACHE_DIR="${EBZR_CACHE_DIR:-${PN}}"
116 116
117# @ECLASS-VARIABLE: EBZR_OFFLINE
118# @DESCRIPTION:
119# Set this variable to a non-empty value to disable the automatic updating of
120# a bzr source tree. This is intended to be set outside the ebuild by users.
121EBZR_OFFLINE="${EBZR_OFFLINE:-${ESCM_OFFLINE}}"
122
117# @FUNCTION: bzr_initial_fetch 123# @FUNCTION: bzr_initial_fetch
118# @DESCRIPTION: 124# @DESCRIPTION:
119# Retrieves the source code from a repository for the first time, via 125# Retrieves the source code from a repository for the first time, via
120# ${EBZR_FETCH_CMD}. 126# ${EBZR_FETCH_CMD}.
121bzr_initial_fetch() { 127bzr_initial_fetch() {
134# @DESCRIPTION: 140# @DESCRIPTION:
135# Updates the source code from a repository, via ${EBZR_UPDATE_CMD}. 141# Updates the source code from a repository, via ${EBZR_UPDATE_CMD}.
136bzr_update() { 142bzr_update() {
137 local repository="${1}"; 143 local repository="${1}";
138 144
139 # update branch 145 if [[ -n "${EBZR_OFFLINE"} ]]; then
140 einfo "bzr update start -->" 146 einfo "skipping bzr update -->"
141 einfo " repository: ${repository}" 147 einfo " repository: ${repository}"
148 else
149 # update branch
150 einfo "bzr update start -->"
151 einfo " repository: ${repository}"
142 152
143 pushd "${EBZR_BRANCH_DIR}" > /dev/null 153 pushd "${EBZR_BRANCH_DIR}" > /dev/null
144 ${EBZR_UPDATE_CMD} ${EBZR_OPTIONS} \ 154 ${EBZR_UPDATE_CMD} ${EBZR_OPTIONS} \
145 || die "${EBZR}: can't update from ${repository}." 155 || die "${EBZR}: can't update from ${repository}."
146 popd > /dev/null 156 popd > /dev/null
157 fi
147} 158}
148 159
149 160
150# @FUNCTION: bzr_fetch 161# @FUNCTION: bzr_fetch
151# @DESCRIPTION: 162# @DESCRIPTION:

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4

  ViewVC Help
Powered by ViewVC 1.1.20