Re: Removing old versions
Horst Graffy <[email protected]> Thu, 13 Jan 2005 20:11:13 +0100
| Newsgroups | gmane.linux.conectiva.apt-rpm |
|---|---|
| Message-ID | <[email protected]> |
Am Donnerstag, 13. Januar 2005 19:40 schrieb Andre Costa:
> Hi Horst,
>
> thks for sharing your solution. It is Debian-oriented, isn't it? It
> complained about 'deb' not being installed:
no it is ported for rpm. but it uses deb for dpkg calls.
>
> I am running apt-get on Fedora 1 here... is 'deb' really required?
Yes, because dpkg --compare-versions is doing the major work ;)
And the RPM deb is available for FC1, AFAIK.
I have a second Version with another rpm-version comparing tool.
Compile rvc (attached) and change the call in the python script. The test of
the return codes has to changed too.
this part has to be changed:
argz=['dpkg','--compare-versions',parsed[1],'lt',packages[parsed[0]]]
rc=os.spawnvp(os.P_WAIT,'dpkg',argz)
if rc==2: continue
if rc==0:
print "\tDeleting",file
if not dryrun: os.unlink(dir+file)
continue
elif rc==1:
print "\tDeleting",fnames[parsed[0]]
if not dryrun: os.unlink(dir+fnames[parsed[0]])
My RPMs are signed, you can import my rpm-key from here:
http://ftp.gwdg.de/pub/linux/suse/apt/SuSE/9.2-i386/RPMS.suser-oc2pus/rpmkey-suser-oc2pus-0.1-0.noarch.rpm
CU
Toni
_______________________________________________
apt-rpm mailing list
[email protected]
http://distro2.conectiva.com.br/mailman/listinfo/apt-rpm
rvc.tar.gz
(application/x-tgz, 2.6 KB) - not displayed