view contrib/dockerrpm @ 21537:1ab30e9ba0fc

update: specify custom conflict markers for update (BC) Add custom conflict markers 'working copy' and 'destination' for doing hg update when there are conflicts between your working copy and the destination.
author Durham Goode <durham@fb.com>
date Fri, 09 May 2014 18:09:11 -0700
parents 62a2749895e4
children f1bcc33a5c52
line wrap: on
line source

#!/bin/bash

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

if which docker >> /dev/null ; then
  DOCKER=docker
elif which docker.io >> /dev/null ; then
  DOCKER=docker.io
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 build/$1/* /hg/build/$1/"