Abort requirement document creation on error
This commit is contained in:
parent
368b42c1ae
commit
ed0d9da243
@ -1,5 +1,6 @@
|
||||
import optparse
|
||||
import os
|
||||
import sys
|
||||
|
||||
import xml_parser
|
||||
import reqif_conv
|
||||
@ -83,4 +84,4 @@ if __name__ == '__main__':
|
||||
tex_path = os.path.abspath(os.path.splitext(reqif_path)[0] + '.tex')
|
||||
reqif_data = reqif_dict(reqif_path, 'Heading', 'Software Specification')
|
||||
reqif_conv.tex_gen(reqif_data, tex_path)
|
||||
reqif_conv.pdf_gen(tex_path)
|
||||
sys.exit(reqif_conv.pdf_gen(tex_path))
|
||||
|
@ -30,6 +30,8 @@ def pdf_gen(tex_path):
|
||||
exit_value = os.system("pdflatex -interaction nonstopmode %s 1> /dev/null" % tex_path)
|
||||
if exit_value != 0:
|
||||
print('FAILED')
|
||||
return -1
|
||||
break
|
||||
else:
|
||||
print('SUCCESS')
|
||||
return 0
|
||||
|
Loading…
x
Reference in New Issue
Block a user