view contrib/dockerrpm @ 21644:17755dd8c509

bundle2: introduce a bundle2caps function The process of decoding remote bundle2caps blob into a dictionary is cumbersome. We move it into a small helper function. This will clarify code that reads bundle2 capabilities of peers and helps using it in new places.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Sat, 24 May 2014 16:20:09 -0700
parents 76a347bcdb33
children f5abb231b80a
line wrap: on
line source

#!/bin/bash

BUILDDIR=$(dirname $0)
ROOTDIR=$(cd $BUILDDIR/..; pwd)

if which docker.io >> /dev/null ; then
  DOCKER=docker.io
elif which docker >> /dev/null ; then
  DOCKER=docker
fi

$DOCKER build --tag "hg-dockerrpm-$1" - < $BUILDDIR/docker/$1
$DOCKER run --rm -v $ROOTDIR:/hg "hg-dockerrpm-$1" bash -c \
    "cp -a hg hg-build; cd hg-build; make clean local $1; cp packages/$1/* /hg/packages/$1/"