2016-08-19 06:29:30 +01:00
|
|
|
source $stdenv/setup
|
2016-08-19 21:55:10 +01:00
|
|
|
header "Cloning Fossil $url [$rev] into $out"
|
2016-08-19 06:29:30 +01:00
|
|
|
|
|
|
|
# Fossil, bless its adorable little heart, wants to write global configuration
|
|
|
|
# to $HOME/.fossil. AFAICT, there is no way to disable this functionality.
|
2016-08-19 07:16:37 +01:00
|
|
|
# Instead, we'll let it write to the build directory.
|
|
|
|
export HOME=$(pwd)
|
2016-08-19 06:29:30 +01:00
|
|
|
|
|
|
|
# We must explicitly set the admin user for the clone to something reasonable.
|
|
|
|
fossil clone -A nobody "$url" fossil-clone.fossil
|
|
|
|
|
|
|
|
mkdir fossil-clone
|
|
|
|
WORKDIR=$(pwd)
|
|
|
|
mkdir $out
|
|
|
|
pushd $out
|
2016-08-19 21:55:10 +01:00
|
|
|
fossil open "$WORKDIR/fossil-clone.fossil" "$rev"
|
2016-08-19 06:29:30 +01:00
|
|
|
popd
|
|
|
|
|
|
|
|
# Just nuke the checkout file.
|
|
|
|
rm $out/.fslckout
|
|
|
|
|
|
|
|
stopNest
|