1
0
mirror of https://github.com/openSUSE/osc.git synced 2025-01-11 16:36:14 +01:00

- do_addchannels: handle wrong args more gracefully

This commit is contained in:
Marcus Huewe 2015-07-15 20:46:38 +02:00
parent 0daec6a5f1
commit e9d7ac9c82

View File

@ -470,7 +470,8 @@ class Osc(cmdln.Cmdln):
elif is_package_dir(localdir): elif is_package_dir(localdir):
project = store_read_project(localdir) project = store_read_project(localdir)
channel = store_read_package(localdir) channel = store_read_package(localdir)
# XXX: error handling? else:
raise oscerr.WrongArgs('Either specify project [package] or call it from a project/package working copy')
else: else:
project = args[0] project = args[0]
if len(args) > 1: if len(args) > 1: