Verified Commit 063113dd authored by Adam Mercer's avatar Adam Mercer
Browse files

move check that source exists into main()

parent 5af143ea
......@@ -59,13 +59,6 @@ def parse_options():
# parse options
args = parser.parse_args()
# check that source-rpm exists
if args.git:
source = pathlib.Path(args.source)
if not source.is_file():
print('File %s does not exist.' % args.source)
sys.exit(1)
return args
......@@ -105,6 +98,13 @@ def main():
# check that we can authenticate to koji
check_connection_to_koji()
# check that source exists
if args.git:
source = pathlib.Path(args.source)
if not source.is_file():
print('File %s does not exist.' % args.source)
sys.exit(1)
# get pkg name from source rpm
pkg_name = get_package_name_from_source_rpm(args.source)
if args.verbose:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment