Print help when no file provided

Signed-off-by: Juraj Oravec <jurajoravec@mailo.com>
This commit is contained in:
Juraj Oravec 2024-05-12 20:15:02 +02:00
parent bd70b22a7a
commit 0b71705c16
Signed by: SGOrava
GPG Key ID: 13660A3F1D9F093B

View File

@ -317,6 +317,9 @@ def main():
configuration['include_file_name'] = args.include_file_name configuration['include_file_name'] = args.include_file_name
if not args.elf_file:
parser.print_help()
exit(1)
if not os.path.exists(args.elf_file): if not os.path.exists(args.elf_file):
eprint('File {elf_file} does not exist!'.format(elf_file=args.elf_file)) eprint('File {elf_file} does not exist!'.format(elf_file=args.elf_file))
exit(1) exit(1)