]> git.decadent.org.uk Git - dak.git/blob - christina
add symlinks to suggests; up version dependency on gnupg
[dak.git] / christina
1 #!/usr/bin/env python
2
3 # ???
4 # Copyright (C) 2000, 2001  James Troup <james@nocrew.org>
5 # $Id: christina,v 1.1 2001-03-21 01:03:41 troup Exp $
6
7 # This program is free software; you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation; either version 2 of the License, or
10 # (at your option) any later version.
11
12 # This program is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 # GNU General Public License for more details.
16
17 # You should have received a copy of the GNU General Public License
18 # along with this program; if not, write to the Free Software
19 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
20
21 ################################################################################
22
23 # <Omnic> elmo wrote docs?!!?!?!?!?!?!
24 # <aj> as if he wasn't scary enough before!!
25 # * aj imagines a little red furry toy sitting hunched over a computer
26 #   tapping furiously and giggling to himself
27 # <aj> eventually he stops, and his heads slowly spins around and you
28 #      see this really evil grin and then he sees you, and picks up a
29 #      knife from beside the keyboard and throws it at you, and as you
30 #      breathe your last breath, he starts giggling again
31 # <aj> but i should be telling this to my psychiatrist, not you guys,
32 #      right? :)
33
34 ################################################################################
35
36 import pg, sys, os, string
37 import utils, db_access
38 import apt_pkg;
39
40 ################################################################################
41
42 Cnf = None;
43 projectB = None;
44
45 ################################################################################
46
47 def main ():
48     global Cnf, projectB, db_files, waste, excluded;
49
50     apt_pkg.init();
51     
52     Cnf = apt_pkg.newConfiguration();
53     apt_pkg.ReadConfigFileISC(Cnf,utils.which_conf_file());
54
55     Arguments = [('d',"debug","Christina::Options::Debug", "IntVal"),
56                  ('h',"help","Christina::Options::Help"),
57                  ('v',"version","Christina::Options::Version")];
58
59     apt_pkg.ParseCommandLine(Cnf,Arguments,sys.argv);
60     projectB = pg.connect(Cnf["DB::Name"], Cnf["DB::Host"], int(Cnf["DB::Port"]));
61     db_access.init(Cnf, projectB);
62
63 #######################################################################################
64
65 if __name__ == '__main__':
66     main()
67