apply patch from Murray Jensen to fix lost CVS_RSH when doing incremental update
[vuplus_bitbake] / bin / oeread
1 #!/usr/bin/env python
2 # ex:ts=4:sw=4:sts=4:et
3 # -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*-
4
5 import sys, copy, oe, oe.parse, oe.build
6 #from oe import *
7
8 d = oe.data.init()
9 d = oe.parse.handle("conf/oe.conf", d)
10
11 if len(sys.argv) == 2:
12     try:
13         d = oe.parse.handle(sys.argv[1], d)
14     except Exception, e:
15         oe.fatal("%s" % e)
16
17 # emit variables and shell functions
18 oe.data.emit_env(sys.__stdout__, d, True)
19 # emit the metadata which isnt valid shell
20 for e in d.keys():
21     if oe.data.getVarFlag(e, 'python', d):
22         sys.__stdout__.write("\npython %s () {\n%s}\n" % (e, oe.data.getVar(e, d, 1)))