~launchpad-pqm/launchpad/devel

10637.3.1 by Guilherme Salgado
Use the default python version instead of a hard-coded version
1
#!/usr/bin/python -S
8687.15.22 by Karl Fogel
Add the copyright header block to the remaining .py files.
2
#
3
# Copyright 2009 Canonical Ltd.  This software is licensed under the
4
# GNU Affero General Public License version 3 (see the file LICENSE).
5
7675.144.1 by Jeroen Vermeulen
Porting over the whole diff from other branch to avoid collateral diff damage.
6
# pylint: disable-msg=W0403
7
8
__metaclass__ = type
9
10
import _pythonpath
11
14612.2.7 by William Grant
scripts
12
from lp.translations.translationmerger import MessageSharingMerge
8778.1.1 by Jeroen Vermeulen
Fixed import issues from tree reorg, added test.
13
7675.144.1 by Jeroen Vermeulen
Porting over the whole diff from other branch to avoid collateral diff damage.
14
# This script merges POTMsgSets for sharing POTemplates.  This involves
15
# deleting records that we'd never delete otherwise.  So before running,
16
# make sure rosettaadmin has the privileges to delete POTMsgSets and
17
# TranslationTemplateItems:
18
#
19
# GRANT DELETE ON POTMsgSET TO rosettaadmin;
10303.1.1 by Gary Poster
use newest version of zc.buildout
20
# GRANT DELETE ON  TranslationTemplateItem TO rosettaadmin;
7675.144.1 by Jeroen Vermeulen
Porting over the whole diff from other branch to avoid collateral diff damage.
21
22
23
if __name__ == '__main__':
7675.174.6 by Jeroen Vermeulen
Prototyped TranslationMessage merge. Renamed migration script to cover both. Support operating on entire distro for testing.
24
    script = MessageSharingMerge(
14565.2.15 by Curtis Hovey
Moved canonical.launchpad.scripts __init__ to lp.services.scripts.
25
        'lp.services.scripts.message-sharing-merge',
7675.174.6 by Jeroen Vermeulen
Prototyped TranslationMessage merge. Renamed migration script to cover both. Support operating on entire distro for testing.
26
        dbuser='rosettaadmin')
7675.144.1 by Jeroen Vermeulen
Porting over the whole diff from other branch to avoid collateral diff damage.
27
    script.run()