feat: return 1 if output has problems
This commit is contained in:
parent
95da29454a
commit
e9b1ab5f85
3 changed files with 7 additions and 4 deletions
|
@ -1,6 +1,6 @@
|
|||
"""
|
||||
Silique (https://www.silique.fr)
|
||||
Copyright (C) 2024
|
||||
Copyright (C) 2024-2025
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
"""
|
||||
Silique (https://www.silique.fr)
|
||||
Copyright (C) 2024
|
||||
Copyright (C) 2024-2025
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
|
@ -37,6 +37,7 @@ def _main():
|
|||
rougailconfig = get_rougail_config(
|
||||
backward_compatibility=False, add_extra_options=False
|
||||
)
|
||||
rougailconfig.generate_config()
|
||||
cmd_config = rougailconfig.config
|
||||
origin_prop = cmd_config.property.default('read_write', 'append')
|
||||
cmd_config.property.setdefault(frozenset(origin_prop | {"not_for_commandline"}), 'read_write', 'append')
|
||||
|
@ -117,12 +118,14 @@ def _main():
|
|||
_('cannot find cli file for "output_name" module "{0}"').format(output_name)
|
||||
)
|
||||
module = load_modules("rougail.output_" + output_name, str(path))
|
||||
module.RougailOutput(
|
||||
ret = module.RougailOutput(
|
||||
config=config,
|
||||
rougailconfig=rougailconfig,
|
||||
user_data_errors=err_warn["errors"],
|
||||
user_data_warnings=err_warn["warnings"],
|
||||
).print()
|
||||
if ret is False:
|
||||
exit(1)
|
||||
|
||||
|
||||
def main():
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
"""Internationalisation utilities
|
||||
Silique (https://www.silique.fr)
|
||||
Copyright (C) 2024
|
||||
Copyright (C) 2024-2025
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
|
|
Loading…
Reference in a new issue