1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 import fcntl
18 import itertools
19 import optparse
20 import os
21 import sys
22 import time
23
24 from conary.conaryclient import callbacks as clientCallbacks
25 from conary import conarycfg, callbacks, trove
26 from conary.lib import cfg, util, log
27 from conary.repository import errors, changeset, netclient
28
30 - def __init__(self, errcode, errmsg, *args):
31 self.errcode = errcode
32 self.errmsg = errmsg
33 Exception.__init__(self, *args)
34
36 parser = optparse.OptionParser(version = '%prog 0.1')
37 parser.add_option("--config-file", dest = "configFile",
38 help = "configuration file", metavar = "FILE")
39 parser.add_option("--full-sig-sync", dest = "infoSync",
40 action = "store_true", default = False,
41 help = "deprecated: alias to --full-info-sync")
42 parser.add_option("--full-info-sync", dest = "infoSync",
43 action = "store_true", default = False,
44 help = "replace all the trove signatures and metadata "
45 "in the target repository")
46 parser.add_option("--fast-sync", dest = "fastSync",
47 action = "store_true", default = False,
48 help = "skip checking/mirroring of changed info records "
49 "for already mirrored troves")
50 parser.add_option("--absolute", dest = "absolute",
51 action = "store_true", default = False,
52 help = "use only absolute changesets when mirroring content")
53 parser.add_option("--full-trove-sync", dest = "sync", action = "store_true",
54 default = False,
55 help = "ignore the last-mirrored timestamp in the "
56 "target repository")
57 parser.add_option("--check-sync", dest = "checkSync", action = "store_true",
58 default = False,
59 help = "only check if the source and target(s) are in sync")
60 parser.add_option("--test", dest = "test", action = "store_true",
61 default = False,
62 help = "skip commiting changes to the target repository")
63 parser.add_option("-v", "--verbose", dest = "verbose",
64 action = "store_true", default = False,
65