Mailinglist Archive: zypp-devel (226 mails)

< Previous Next >
Re: [zypp-devel] very weird zypper behaviour
  • From: Jano Kupec <jkupec@xxxxxxx>
  • Date: Thu, 17 Apr 2008 23:30:51 +0200
  • Message-id: <4807C18B.1040005@xxxxxxx>
Jan-Simon Möller wrote:
I can remove the code doing this in a minute, but i'd appreciate
suggestions how to do this 'zypper install zypper-0.11.1'....

Reading the thread and you last sentence, i just thought on

zypper install zypper@xxxxxx

"@" is commonly used and it felt "natural" here ...

Yes, you can already use '=' (zypper install zypper=0.11.1), no problem with that, but there were specific requests to be able to use also dash instead of the '=' (since the packages with version are often described like that).

Also, rug is doing it somehow (curious :O) with the dash, and we should be compatible with rug as much as possible.


I disabled the code for now... in case anybody is interested, here it is:

// try to find foo-bar-1.2.3-2
if (!by_capability && str.find('-') != string::npos)
{
string::size_type pos = 0;
while ((pos = str.find('-', pos)) != string::npos)
{
string trythis = str;
trythis.replace(pos, 1, 1, '=');

DBG << "trying: " << trythis << endl;

Capability cap = safe_parse_cap (zypper, trythis, kind);
sat::WhatProvides q(cap);

if (!q.empty())
{
str = trythis;
by_capability = true;
DBG << str << "might be what we wanted" << endl;
break;
}
++pos;
}
}


jano
--
To unsubscribe, e-mail: zypp-devel+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-devel+help@xxxxxxxxxxxx

< Previous Next >