fixes to postgres, shell. removal of "run" module.

This commit is contained in:
percious17 2008-12-02 18:27:16 +00:00
parent 2e74b87df5
commit 6c0694417f
4 changed files with 24 additions and 8 deletions

View File

@ -1,9 +1,10 @@
0.5.0
- SA 0.5.x support.
- TODO:py.test is no longer used for testing. (use nose)
- py.test is no longer used for testing. (use nose)
- Added --echo=True option for all commands, which will make the sqlalchemy connection echo SQL statements.
- Better Postgres support, especially for schemas.
- modification to the downgrade command to simplify the calling (old way still works just fine)
- TODO: complete MySQL support
0.4.x
- TODO: document changes

View File

@ -1 +0,0 @@
from migrate.run import *

View File

@ -11,19 +11,34 @@ class PGSchemaGeneratorMixin(object):
return '"%s"'%identifier
class PGColumnGenerator(PGSchemaGenerator,ansisql.ANSIColumnGenerator, PGSchemaGeneratorMixin):
pass
def _do_quote_table_identifier(self, identifier):
return identifier
def _do_quote_column_identifier(self, identifier):
return '"%s"'%identifier
class PGColumnDropper(ansisql.ANSIColumnDropper, PGSchemaGeneratorMixin):
pass
def _do_quote_table_identifier(self, identifier):
return identifier
def _do_quote_column_identifier(self, identifier):
return '"%s"'%identifier
class PGSchemaChanger(ansisql.ANSISchemaChanger, PGSchemaGeneratorMixin):
pass
def _do_quote_table_identifier(self, identifier):
return identifier
def _do_quote_column_identifier(self, identifier):
return '"%s"'%identifier
class PGConstraintGenerator(ansisql.ANSIConstraintGenerator, PGSchemaGeneratorMixin):
pass
def _do_quote_table_identifier(self, identifier):
return identifier
def _do_quote_column_identifier(self, identifier):
return '"%s"'%identifier
class PGConstraintDropper(ansisql.ANSIConstraintDropper, PGSchemaGeneratorMixin):
pass
def _do_quote_table_identifier(self, identifier):
return identifier
def _do_quote_column_identifier(self, identifier):
return '"%s"'%identifier
class PGDialect(ansisql.ANSIDialect):
columngenerator = PGColumnGenerator

View File

@ -92,6 +92,7 @@ def parse_args(*args,**kwargs):
if cmdname == 'downgrade':
if not args[-1].startswith('--'):
kwargs['version'] = args[-1]
args = args[:-1]
except IndexError:
# No command specified: no error message; just show usage