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

suggesting 'osc ls /' for listing all projects.

This commit is contained in:
Juergen Weigert 2010-12-02 23:52:38 +01:00
parent 2fd0f1cb95
commit 200807fb37

View File

@ -223,6 +223,7 @@ class Osc(cmdln.Cmdln):
Examples for listing sources: Examples for listing sources:
ls # list all projects (deprecated) ls # list all projects (deprecated)
ls / # list all projects
ls PROJECT # list packages in a project ls PROJECT # list packages in a project
ls PROJECT PACKAGE # list source files of package of a project ls PROJECT PACKAGE # list source files of package of a project
ls PROJECT PACKAGE <file> # list <file> if this file exists ls PROJECT PACKAGE <file> # list <file> if this file exists
@ -259,8 +260,14 @@ class Osc(cmdln.Cmdln):
project = None project = None
package = None package = None
fname = None fname = None
if len(args) == 0:
# For consistency with *all* other commands
# this list what the server has in the current wd.
# CAUTION: 'osc ls -b' already works like this.
pass
if len(args) > 0: if len(args) > 0:
project = args[0] project = args[0]
if project == '/': project = None
if len(args) > 1: if len(args) > 1:
package = args[1] package = args[1]
if opts.deleted: if opts.deleted: