On Mon, Aug 23, 2010 at 23:23, Robin H. Johnson <[email protected]> wrote:
> Index: mercurial.eclass
> ===================================================================
> RCS file: /var/cvsroot/gentoo-x86/eclass/mercurial.eclass,v
> retrieving revision 1.12
> diff -p -w -b -B -u -r1.12 mercurial.eclass
> --- mercurial.eclass    2 Apr 2010 18:29:39 -0000       1.12
> +++ mercurial.eclass    23 Aug 2010 21:20:41 -0000
> @@ -116,12 +116,20 @@ function mercurial_fetch {
>        fi
>
>        # Checkout working copy:
> -       einfo "Creating working directory in ${WORKDIR}/${module} (revision: 
> ${EHG_REVISION})"
> +       einfo "Creating working directory in ${WORKDIR}/${module} (target 
> revision: ${EHG_REVISION})"
>        hg clone \
>                ${EHG_QUIET_CMD_OPT} \
>                --rev="${EHG_REVISION}" \
>                "${EHG_STORE_DIR}/${EHG_PROJECT}/${module}" \
>                "${WORKDIR}/${module}" || die "hg clone failed"
> +       # An exact revision helps a lot for testing purposes, so have some 
> output...
> +       # id           num  branch
> +       # fd6e32d61721 6276 default
> +       local HG_REVDATA=($(hg identify -n -b -i "${WORKDIR}/${module}"))
> +       local HG_REV_ID=${HG_REVDATA[0]}
> +       local HG_REV_NUM=${HG_REVDATA[1]}
> +       local HG_REV_BRANCH=${HG_REVDATA[2]}
> +       einfo "Work directory: ${WORKDIR}/${module} global id: ${HG_REV_ID} 
> branch: ${HG_REV_BRANCH}"
>  }

I'd leave out the HG_REV_NUM, it doesn't mean much anyway (since it is
local to a repository, it can easily change).

Cheers,

Dirkjan

Reply via email to