~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to database/replication/preamble.py

  • Committer: Jeroen Vermeulen
  • Date: 2011-09-19 06:57:55 UTC
  • mto: This revision was merged to the branch mainline in revision 13994.
  • Revision ID: jeroen.vermeulen@canonical.com-20110919065755-lgot1hi4xfqrf492
Lint.  Lots of lint.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#!/usr/bin/python -S
2
2
#
3
 
# Copyright 2009 Canonical Ltd.  This software is licensed under the
 
3
# Copyright 2009-2011 Canonical Ltd.  This software is licensed under the
4
4
# GNU Affero General Public License version 3 (see the file LICENSE).
5
5
 
6
6
"""Generate a preamble for slonik(1) scripts based on the current LPCONFIG.
9
9
__metaclass__ = type
10
10
__all__ = []
11
11
 
 
12
from optparse import OptionParser
 
13
import time
 
14
 
12
15
import _pythonpath
13
 
 
14
 
import time
15
 
from optparse import OptionParser
 
16
import replication.helpers
16
17
 
17
18
from canonical.config import config
18
19
from canonical.database.sqlbase import connect
19
20
from canonical.launchpad import scripts
20
21
 
21
 
import replication.helpers
22
22
 
23
23
if __name__ == '__main__':
24
24
    parser = OptionParser()
33
33
    print '# LPCONFIG=%s' % config.instance_name
34
34
    print
35
35
    print replication.helpers.preamble(con)
36