Added optional support for database migrations with south. The game/migrate.py program is a simple wrapper that runs the suitable commands for setting up a database and updating it, respectively.
This commit is contained in:
parent
7eaf3d221c
commit
7fb6362dc4
9 changed files with 153 additions and 30 deletions
|
|
@ -162,7 +162,6 @@ def stop_server(parser, options, args):
|
|||
else:
|
||||
print '\n\rUnknown OS detected, can not stop. '
|
||||
|
||||
|
||||
def main():
|
||||
"""
|
||||
Beginning of the program logic.
|
||||
|
|
@ -176,14 +175,14 @@ def main():
|
|||
dest='interactive',
|
||||
help='Start in daemon mode (default)')
|
||||
(options, args) = parser.parse_args()
|
||||
|
||||
|
||||
if "start" in args:
|
||||
if options.interactive:
|
||||
start_interactive(parser, options, args)
|
||||
else:
|
||||
start_daemon(parser, options, args)
|
||||
elif "stop" in args:
|
||||
stop_server(parser, options, args)
|
||||
stop_server(parser, options, args)
|
||||
else:
|
||||
parser.print_help()
|
||||
if __name__ == '__main__':
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue