1
0
mirror of https://github.com/deadc0de6/dotdrop.git synced 2026-02-09 09:29:17 +00:00

fail if dynvariables cannot be executed successfully

This commit is contained in:
deadc0de6
2019-06-12 10:10:38 +02:00
parent 42f195d7c6
commit 6384516cdc
2 changed files with 12 additions and 3 deletions

View File

@@ -209,7 +209,12 @@ class CfgYaml:
# exec dynvariables
for k in dvar.keys():
allvars[k] = shell(allvars[k])
ret, out = shell(allvars[k])
if not ret:
err = 'command \"{}\" failed: {}'.format(allvars[k], out)
self.log.error(err)
raise YamlException(err)
allvars[k] = out
if self.debug:
self.log.dbg('variables:')