#!/bin/bash

set -e

PATH=/home/heikki/cvs2svn/$PATH cvs2git -v --options=cvs2git.options

mkdir psqlodbc-migrated.git
cd psqlodbc-migrated.git
git init --bare


# Apply some hacks to the commits, before importing them.
perl ../post-hacks.pl < ../cvs2svn-tmp/git-dump.dat > git-dump.dat

# And import.
cat ../cvs2svn-tmp/git-blob.dat git-dump.dat | git fast-import

# Shrink the size of the repo
git gc --prune=now --aggressive
