1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-11-10 06:46:15 +01:00

init: make usage (and usage info) info more precise

This commit is contained in:
Dr. Peter Poeml 2007-06-21 09:40:47 +00:00
parent 0cf26d0f06
commit 751bc409ac

View File

@ -65,7 +65,7 @@ class Osc(cmdln.Cmdln):
conf.init_basicauth(conf.config)
def do_init(self, subcmd, opts, *args):
def do_init(self, subcmd, opts, project, package):
"""${cmd_name}: Initialize a directory as working copy
Initialize a directory to be a working copy of an
@ -75,15 +75,11 @@ class Osc(cmdln.Cmdln):
package and then copying sources into the directory. It does NOT create
a new package. To create a package, use createpac.)
${cmd_usage}
usage:
osc init PRJ PAC
${cmd_option_list}
"""
if len(args) != 2:
print >>sys.stderr, 'Must provide project and package name.'
return 2
project = args[0]
package = args[1]
init_package_dir(conf.config['apiurl'], project, package, os.path.curdir)
print 'Initializing %s (Project: %s, Package: %s)' % (os.curdir, project, package)