projects
/
cdist.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
c2627a7
)
Fix mis-named variable and fix building in a specified directory using docker.
author
Carl Hetherington
<cth@carlh.net>
Thu, 2 Apr 2020 18:27:13 +0000
(20:27 +0200)
committer
Carl Hetherington
<cth@carlh.net>
Thu, 2 Apr 2020 18:27:13 +0000
(20:27 +0200)
cdist
patch
|
blob
|
history
diff --git
a/cdist
b/cdist
index ff04fdf3002d4e92cafb5a603364a42d46a037ba..8d3fe6fb982646f02e9840fe8bbc57659447fcdf 100755
(executable)
--- a/
cdist
+++ b/
cdist
@@
-323,11
+323,11
@@
def get_options(args, target):
if len(b) != 2:
raise Error("Bad option `%s'" % o)
if b[1] == 'False':
if len(b) != 2:
raise Error("Bad option `%s'" % o)
if b[1] == 'False':
- opts[b[0]] = False
+ opt
ion
s[b[0]] = False
elif b[1] == 'True':
elif b[1] == 'True':
- opts[b[0]] = True
+ opt
ion
s[b[0]] = True
else:
else:
- opts[b[0]] = b[1]
+ opt
ion
s[b[0]] = b[1]
# Add defaults for any unspecified options
tree = globals.trees.get(args.project, args.checkout, target)
tree.add_defaults(options)
# Add defaults for any unspecified options
tree = globals.trees.get(args.project, args.checkout, target)
tree.add_defaults(options)
@@
-1086,6
+1086,8
@@
def main():
if args.work is not None:
args.work = os.path.abspath(args.work)
if args.work is not None:
args.work = os.path.abspath(args.work)
+ if not os.path.exists(args.work):
+ os.makedirs(args.work)
if args.project is None and args.command != 'shell':
raise Error('you must specify -p or --project')
if args.project is None and args.command != 'shell':
raise Error('you must specify -p or --project')