mirror of
https://github.com/facebook/sapling.git
synced 2024-10-10 16:57:49 +03:00
979732847b
This prevents lots of useless test output if lz4 is missing on a machine.
44 lines
639 B
Bash
44 lines
639 B
Bash
python -c 'import lz4' || exit 80
|
|
|
|
cp `echo $HGRCPATH` ./
|
|
CACHEDIR=$PWD/hgcache
|
|
cat >> .hgrc <<EOF
|
|
[remotefilelog]
|
|
cachepath=$CACHEDIR
|
|
debug=True
|
|
[extensions]
|
|
remotefilelog=$TESTDIR/../remotefilelog
|
|
rebase=
|
|
mq=
|
|
[ui]
|
|
ssh=python "$TESTDIR/dummyssh"
|
|
[server]
|
|
preferuncompressed=True
|
|
EOF
|
|
export HGRCPATH=$PWD/.hgrc
|
|
|
|
hgcloneshallow() {
|
|
local name
|
|
local dest
|
|
orig=$1
|
|
shift
|
|
dest=$1
|
|
shift
|
|
hg clone --shallow --config remotefilelog.reponame=master $orig $dest $@
|
|
cat >> $dest/.hg/hgrc <<EOF
|
|
[remotefilelog]
|
|
reponame=master
|
|
EOF
|
|
}
|
|
|
|
hginit() {
|
|
local name
|
|
name=$1
|
|
shift
|
|
hg init $name $@
|
|
}
|
|
|
|
clearcache() {
|
|
rm -rf $CACHEDIR/*
|
|
}
|