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

Diff of /eclass/mercurial.eclass

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

Revision 1.7 Revision 1.8
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/mercurial.eclass,v 1.7 2009/09/29 21:51:33 nelchael Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/mercurial.eclass,v 1.8 2009/12/11 21:02:29 robbat2 Exp $
4 4
5# @ECLASS: mercurial.eclass 5# @ECLASS: mercurial.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# nelchael@gentoo.org 7# nelchael@gentoo.org
8# @BLURB: This eclass provides generic mercurial fetching functions 8# @BLURB: This eclass provides generic mercurial fetching functions
33# 33#
34# This variable default to $PN, but can be changed to allow repository sharing 34# This variable default to $PN, but can be changed to allow repository sharing
35# between several ebuilds. 35# between several ebuilds.
36[[ -z "${EHG_PROJECT}" ]] && EHG_PROJECT="${PN}" 36[[ -z "${EHG_PROJECT}" ]] && EHG_PROJECT="${PN}"
37 37
38# @ECLASS-VARIABLE: EHG_QUIET
39# @DESCRIPTION:
40# Suppress some extra noise from mercurial, set it to 'OFF' to be louder.
41: ${EHG_QUIET:="ON"}
42[[ "${EHG_QUIET}" == "ON" ]] && EHG_QUIET_CMD_OPT="--quiet"
43
38# @ECLASS-VARIABLE: EHG_CLONE_CMD 44# @ECLASS-VARIABLE: EHG_CLONE_CMD
39# @DESCRIPTION: 45# @DESCRIPTION:
40# Command used to perform initial repository clone. 46# Command used to perform initial repository clone.
41[[ -z "${EHG_CLONE_CMD}" ]] && EHG_CLONE_CMD="hg clone --quiet --pull --noupdate" 47[[ -z "${EHG_CLONE_CMD}" ]] && EHG_CLONE_CMD="hg clone ${EHG_QUIET_CMD_OPT} --pull --noupdate"
42 48
43# @ECLASS-VARIABLE: EHG_PULL_CMD 49# @ECLASS-VARIABLE: EHG_PULL_CMD
44# @DESCRIPTION: 50# @DESCRIPTION:
45# Command used to update repository. 51# Command used to update repository.
46[[ -z "${EHG_PULL_CMD}" ]] && EHG_PULL_CMD="hg pull --quiet" 52[[ -z "${EHG_PULL_CMD}" ]] && EHG_PULL_CMD="hg pull ${EHG_QUIET_CMD_OPT}"
47 53
48# @ECLASS-VARIABLE: EHG_OFFLINE 54# @ECLASS-VARIABLE: EHG_OFFLINE
49# @DESCRIPTION: 55# @DESCRIPTION:
50# Set this variable to a non-empty value to disable the automatic updating of 56# Set this variable to a non-empty value to disable the automatic updating of
51# a mercurial source tree. This is intended to be set outside the ebuild by 57# a mercurial source tree. This is intended to be set outside the ebuild by
102 fi 108 fi
103 109
104 # Checkout working copy: 110 # Checkout working copy:
105 einfo "Creating working directory in ${WORKDIR}/${module} (revision: ${EHG_REVISION})" 111 einfo "Creating working directory in ${WORKDIR}/${module} (revision: ${EHG_REVISION})"
106 hg clone \ 112 hg clone \
107 --quiet \ 113 ${EHG_QUIET_CMD_OPT} \
108 --rev="${EHG_REVISION}" \ 114 --rev="${EHG_REVISION}" \
109 "${hg_src_dir}/${EHG_PROJECT}/${module}" \ 115 "${hg_src_dir}/${EHG_PROJECT}/${module}" \
110 "${WORKDIR}/${module}" || die "hg clone failed" 116 "${WORKDIR}/${module}" || die "hg clone failed"
111} 117}
112 118

Legend:
Removed from v.1.7  
changed lines
  Added in v.1.8

  ViewVC Help
Powered by ViewVC 1.1.20