This guide will demonstrate how to mirror an SVN into a Git repo. You're the target audience if you're an SVN user, just getting started with Git and need to coax your project team over to Git.
The branching scenario has been simplified for clarity.
| #!/bin/bash | |
| # Runs any command (the args) in the virtualenv environment where this script resides. | |
| # You need to change the ACTIVATE_PATH variable | |
| # depending on where your virtualenv activate file is relative to this script. | |
| # The WORKING_DIR var controls the directory from which the command will be run. | |
| # I put this in a bin folder at the top level of my app. | |
| # my virtualenv structure: | |
| # /my_env | |
| # /my_env/bin ( with the venv activate script ) | |
| # /my_env/my_app |
| from django import forms | |
| from django.utils.translation import ugettext_lazy as _ | |
| from django.utils.datastructures import MultiValueDict, MergeDict | |
| from django.core import validators | |
| from django.core.exceptions import ValidationError | |
| try: | |
| from cStringIO import StringIO | |
| except ImportError: | |
| from StringIO import StringIO |
| from mongokit import Document | |
| class Sequential(Document): | |
| __collection__ = 'sequential' | |
| structure = { | |
| '_id': basestring, | |
| 'next': long | |
| } | |
| indexes = [{ 'fields': ['_id'], 'unique': True }] |