* update comar interface
* up the antenna a bit * w00t
This commit is contained in:
@@ -1,16 +1,15 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<!DOCTYPE Project SYSTEM "Project-3.8.dtd">
|
<!DOCTYPE Project SYSTEM "Project-3.8.dtd">
|
||||||
<!-- Project file for project pisi -->
|
<!-- Project file for project pisi -->
|
||||||
<!-- Saved: 2005-09-02, 17:09:47 -->
|
<!-- Saved: 2005-09-20, 16:43:07 -->
|
||||||
<!-- Copyright (C) 2005 PiSi Development Team, pisi@uludag.org.tr -->
|
<!-- Copyright (C) 2005 PiSi Development Team, -->
|
||||||
<Project version="3.8">
|
<Project version="3.8">
|
||||||
<ProgLanguage mixed="0">Python</ProgLanguage>
|
<ProgLanguage mixed="0">Python</ProgLanguage>
|
||||||
<UIType>Qt</UIType>
|
<UIType>Qt</UIType>
|
||||||
<Description>The package management software of Pardus distribution.
|
<Description>The package management software of Pardus distribution.
|
||||||
</Description>
|
</Description>
|
||||||
<VersIon>0.2</VersIon>
|
|
||||||
<Author>PiSi Development Team</Author>
|
<Author>PiSi Development Team</Author>
|
||||||
<EmaIl>pisi@uludag.org.tr</EmaIl>
|
<EmaIl></EmaIl>
|
||||||
<Sources>
|
<Sources>
|
||||||
<Source>
|
<Source>
|
||||||
<Dir>tools</Dir>
|
<Dir>tools</Dir>
|
||||||
@@ -311,6 +310,9 @@
|
|||||||
<Dir>pisi</Dir>
|
<Dir>pisi</Dir>
|
||||||
<Name>specfilenew.py</Name>
|
<Name>specfilenew.py</Name>
|
||||||
</Source>
|
</Source>
|
||||||
|
<Source>
|
||||||
|
<Name>TODO</Name>
|
||||||
|
</Source>
|
||||||
</Sources>
|
</Sources>
|
||||||
<Forms>
|
<Forms>
|
||||||
</Forms>
|
</Forms>
|
||||||
@@ -349,9 +351,9 @@
|
|||||||
</Vcs>
|
</Vcs>
|
||||||
<FiletypeAssociations>
|
<FiletypeAssociations>
|
||||||
<FiletypeAssociation pattern="*.ui.h" type="FORMS" />
|
<FiletypeAssociation pattern="*.ui.h" type="FORMS" />
|
||||||
<FiletypeAssociation pattern="*.ui" type="FORMS" />
|
|
||||||
<FiletypeAssociation pattern="*.idl" type="INTERFACES" />
|
|
||||||
<FiletypeAssociation pattern="*.py" type="SOURCES" />
|
|
||||||
<FiletypeAssociation pattern="*.ptl" type="SOURCES" />
|
<FiletypeAssociation pattern="*.ptl" type="SOURCES" />
|
||||||
|
<FiletypeAssociation pattern="*.idl" type="INTERFACES" />
|
||||||
|
<FiletypeAssociation pattern="*.ui" type="FORMS" />
|
||||||
|
<FiletypeAssociation pattern="*.py" type="SOURCES" />
|
||||||
</FiletypeAssociations>
|
</FiletypeAssociations>
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
@@ -261,11 +261,11 @@ class PackageOp(Command):
|
|||||||
def init(self):
|
def init(self):
|
||||||
super(PackageOp, self).init(True)
|
super(PackageOp, self).init(True)
|
||||||
import pisi
|
import pisi
|
||||||
import pisi.comariface
|
|
||||||
if not self.options.ignore_comar:
|
if not self.options.ignore_comar:
|
||||||
try:
|
try:
|
||||||
pisi.comariface.init()
|
import comar
|
||||||
except pisi.comariface.ComarError:
|
ctx.comard = comar.Link() # context
|
||||||
|
except comar.Error:
|
||||||
ctx.ui.error('Comar error encountered\n')
|
ctx.ui.error('Comar error encountered\n')
|
||||||
self.die()
|
self.die()
|
||||||
|
|
||||||
|
|||||||
@@ -29,6 +29,8 @@ ui = None # not now
|
|||||||
installdb = None
|
installdb = None
|
||||||
repodb = None
|
repodb = None
|
||||||
|
|
||||||
|
comar = None
|
||||||
|
|
||||||
#def register(_impl):
|
#def register(_impl):
|
||||||
# """ Register a UI implementation"""
|
# """ Register a UI implementation"""
|
||||||
# ui = _impl
|
# ui = _impl
|
||||||
|
|||||||
@@ -25,7 +25,6 @@ import pisi.operations as operations
|
|||||||
from pisi.specfile import *
|
from pisi.specfile import *
|
||||||
from pisi.package import Package
|
from pisi.package import Package
|
||||||
from pisi.metadata import MetaData
|
from pisi.metadata import MetaData
|
||||||
from pisi.comariface import comard
|
|
||||||
#import conflicts
|
#import conflicts
|
||||||
|
|
||||||
class InstallError(pisi.Error):
|
class InstallError(pisi.Error):
|
||||||
|
|||||||
+3
-4
@@ -23,7 +23,6 @@ from pisi.uri import URI
|
|||||||
|
|
||||||
def remove_single(package_name):
|
def remove_single(package_name):
|
||||||
"""Remove a single package"""
|
"""Remove a single package"""
|
||||||
from comariface import comard
|
|
||||||
inst_packagedb = packagedb.inst_packagedb
|
inst_packagedb = packagedb.inst_packagedb
|
||||||
|
|
||||||
#TODO: check dependencies
|
#TODO: check dependencies
|
||||||
@@ -32,6 +31,9 @@ def remove_single(package_name):
|
|||||||
if not ctx.installdb.is_installed(package_name):
|
if not ctx.installdb.is_installed(package_name):
|
||||||
raise Exception('Trying to remove nonexistent package '
|
raise Exception('Trying to remove nonexistent package '
|
||||||
+ package_name)
|
+ package_name)
|
||||||
|
if ctx.comard:
|
||||||
|
ctx.comard.remove(package_name)
|
||||||
|
ctx.comard.call("System.Package", "preremove")
|
||||||
for fileinfo in ctx.installdb.files(package_name).list:
|
for fileinfo in ctx.installdb.files(package_name).list:
|
||||||
fpath = os.path.join(ctx.config.destdir, fileinfo.path)
|
fpath = os.path.join(ctx.config.destdir, fileinfo.path)
|
||||||
# TODO: We have to store configuration files for futher
|
# TODO: We have to store configuration files for futher
|
||||||
@@ -44,9 +46,6 @@ def remove_single(package_name):
|
|||||||
os.unlink(fpath)
|
os.unlink(fpath)
|
||||||
ctx.installdb.remove(package_name)
|
ctx.installdb.remove(package_name)
|
||||||
packagedb.remove_package(package_name)
|
packagedb.remove_package(package_name)
|
||||||
if comard:
|
|
||||||
# FIXME: (return value)...
|
|
||||||
comard.remove(package_name)
|
|
||||||
|
|
||||||
def install_single(pkg, upgrade = False):
|
def install_single(pkg, upgrade = False):
|
||||||
"""install a single package from URI or ID"""
|
"""install a single package from URI or ID"""
|
||||||
|
|||||||
@@ -2,8 +2,11 @@
|
|||||||
<A href="http://www.cs.bilkent.edu.tr/~erayo">
|
<A href="http://www.cs.bilkent.edu.tr/~erayo">
|
||||||
<Name>Eray Ozkural</Name>
|
<Name>Eray Ozkural</Name>
|
||||||
<Number>868</Number>
|
<Number>868</Number>
|
||||||
|
<Description>Lazy Tin</Description>
|
||||||
|
<Description xml:lang="tr">Tembel Teneke</Description>
|
||||||
<Projects>
|
<Projects>
|
||||||
<Project>pisi</Project>
|
<Project>pisi</Project>
|
||||||
<Project>noatun</Project>
|
<Project>noatun</Project>
|
||||||
|
<Project>kdevelop</Project>
|
||||||
</Projects>
|
</Projects>
|
||||||
</A>
|
</A>
|
||||||
|
|||||||
Reference in New Issue
Block a user