info, check, index, lr, la, li, build, lc, ls, lu, lp ve sf db'yi

readonly açsınlar. (fixes #2346)
This commit is contained in:
Faik Uygur
2006-04-15 12:19:10 +00:00
parent d8e3422972
commit 1c8630b1b8
+13 -13
View File
@@ -374,7 +374,7 @@ unpack, setup, build, install, package
if ctx.get_option('until') in Build.steps:
raise Error(_('Step must be one of %s ') % pisi.util.strlist(Build.steps))
self.init(database = True)
self.init(database = True, write = False)
if ctx.get_option('output_dir'):
ctx.ui.info(_('Output directory: %s') % ctx.config.options.output_dir)
else:
@@ -613,7 +613,7 @@ Usage: info <package1> <package2> ... <packagen>
def run(self):
self.init(True)
self.init(database = True, write = False)
if len(self.args) == 0:
self.help()
@@ -691,7 +691,7 @@ Usage: check <package1> <package2> ... <packagen>
self.help()
return
self.init(True)
self.init(database = True, write = False)
for pkg in self.args:
if ctx.installdb.is_installed(pkg):
pisi.api.check(pkg)
@@ -730,7 +730,7 @@ source and binary packages.
def run(self):
self.init()
self.init(database = True, write = False)
from pisi.api import index
if len(self.args)>0:
index(self.args, ctx.get_option('output'), skip_sources = ctx.get_option('skip_sources'))
@@ -761,7 +761,7 @@ Usage: list-installed
default=False, help=_("show detailed install info"))
def run(self):
self.init(True)
self.init(database = True, write = False)
list = ctx.installdb.list_installed()
list.sort()
if self.options.install_info:
@@ -930,7 +930,7 @@ Lists currently tracked repositories.
def run(self):
self.init()
self.init(database = True, write = False)
for repo in ctx.repodb.list():
ctx.ui.info(repo)
print ' ', ctx.repodb.get_repo(repo).indexuri.get_uri()
@@ -959,7 +959,7 @@ Gives a brief list of PiSi packages published in the repository.
def run(self):
self.init(True)
self.init(database = True, write = False)
if self.args:
for arg in self.args:
@@ -1011,7 +1011,7 @@ Gives a brief list of PiSi components published in the repositories.
def run(self):
self.init(True)
self.init(database = True, write = False)
list = ctx.componentdb.list_components()
list.sort()
@@ -1048,7 +1048,7 @@ Gives a brief list of sources published in the repositories.
def run(self):
self.init(True)
self.init(database = True, write = False)
list = ctx.sourcedb.list()
list.sort()
@@ -1086,7 +1086,7 @@ Usage: list-upgrades [ <repo1> <repo2> ... repon ]
buildno_opts(self)
def run(self):
self.init(True)
self.init(database = True, write = False)
list = pisi.api.list_upgradable()
if not list:
ctx.ui.info(_('No packages to upgrade.'))
@@ -1118,7 +1118,7 @@ class ListPending(Command):
name = ("list-pending", "lp")
def run(self):
self.init(True)
self.init(database = True, write = False)
list = ctx.installdb.list_pending()
for p in list.keys():
@@ -1155,7 +1155,7 @@ Finds a package in repository containing specified search terms
def run(self):
self.init(True)
self.init(database = True, write = False)
if not self.args:
self.help()
@@ -1213,7 +1213,7 @@ Finds the installed package which contains the specified file.
def run(self):
self.init(True)
self.init(database = True, write = False)
if not self.args:
self.help()