search shouldn't use --names-only

3 views
Skip to first unread message

Reuben Thomas

unread,
Jul 16, 2012, 9:07:08 PM7/16/12
to wa...@googlegroups.com
I recently found that wajig search was pretty much useless, and now I
found out why: it passes --names-only to apt-cache search. Is there a
good reason for this? Now it only searches the names of packages, and
often I am looking for a package with a particular feature, so I am
searching for words in its description, not necessarily in its name!

--
http://rrt.sc3d.org

Tshepang Lekhonkhobe

unread,
Jul 17, 2012, 5:10:37 AM7/17/12
to wa...@googlegroups.com
The normal way of searching can give too many results:

$ wajig search gnome | wc --lines
351
$ wajig search gnome --verbose | wc --lines
1100

Reuben Thomas

unread,
Jul 17, 2012, 5:19:14 AM7/17/12
to wa...@googlegroups.com
On 17 July 2012 10:10, Tshepang Lekhonkhobe <tshe...@gmail.com> wrote:
>
> The normal way of searching can give too many results:
>
> $ wajig search gnome | wc --lines
> 351
> $ wajig search gnome --verbose | wc --lines
> 1100

It's unclear to me that 1100 is "too many" and 351 is not. "wajig
search a" will also give too many results, even without --verbose;
that just means that "a", like "gnome" is a bad search term for most
uses.

--
http://rrt.sc3d.org

Tshepang Lekhonkhobe

unread,
Jul 17, 2012, 5:23:01 AM7/17/12
to wa...@googlegroups.com
Yeah, I get it but it's still available if you want it... use the
--verbose switch.

Also, if we follow your suggestion, what if someone only wants to search
on package names (current default)?

Reuben Thomas

unread,
Jul 17, 2012, 5:24:10 AM7/17/12
to wa...@googlegroups.com
On 17 July 2012 10:23, Tshepang Lekhonkhobe <tshe...@gmail.com> wrote:
>
> Yeah, I get it but it's still available if you want it... use the --verbose
> switch.
>
> Also, if we follow your suggestion, what if someone only wants to search on
> package names (current default)?

--names-only, like apt-cache search? I think apt-cache search's design
is the right one.

--
http://rrt.sc3d.org

Tshepang Lekhonkhobe

unread,
Jul 17, 2012, 5:42:50 AM7/17/12
to wa...@googlegroups.com
Me not sure about that. I like current default behavior. I think it is
more obvious... think of someone who has never used a package search
utility before.

I would change it if other people feel like you though.

Reuben Thomas

unread,
Jul 17, 2012, 6:04:40 AM7/17/12
to wa...@googlegroups.com
Such a person is probably using Software Center, not wajig. And guess
what, Software Center does not just return results whose titles match
the search term!

Anyway, that's the way I've always used wajig, and that's the way it
used to work (unless I am much mistaken?).

--
http://rrt.sc3d.org

Tshepang Lekhonkhobe

unread,
Jul 17, 2012, 6:22:38 AM7/17/12
to wa...@googlegroups.com
Yeah, I did change it in late 2010, and no one complained, until now :)
Maybe wajig does not have that many users, or maybe most just go away
silently when something works differently (i.e. broken in their eyes).

Reuben Thomas

unread,
Jul 17, 2012, 6:24:46 AM7/17/12
to wa...@googlegroups.com
On 17 July 2012 11:22, Tshepang Lekhonkhobe <tshe...@gmail.com> wrote:
>
> Yeah, I did change it in late 2010, and no one complained, until now :)

I should have complained earlier! I noticed the problem some time ago,
but there were other more important things to fix first, I guess, and
it was only just recently that I confirmed that the behaviour really
had changed.

--
http://rrt.sc3d.org

Karl Schmidt

unread,
Jul 17, 2012, 2:47:23 PM7/17/12
to wa...@googlegroups.com
On 07/17/2012 05:22 AM, Tshepang Lekhonkhobe wrote:
> Yeah, I did change it in late 2010, and no one complained, until now :) Maybe wajig does not have
> that many users, or maybe most just go away silently when something works differently (i.e.
> broken in their eyes).

That it isn't in this form in the current stable is the only reason I haven't complained. I'm the
guy that originally requested the feature as in:

$ wajig listall seachterm

It was to replace $ wajig listall |grep searchterm

Which I found I typed several times a day.

I think it is important to realize that wajig exists not only to provide orthogonality to the
package interface, but to help with tasks that the people who use it actually do daily.

Removing or changing these features wholesale is going to cause huge problems if it enters stable in
this form. There are many scipts that call wajig.

If I want to search more than the one line I would use the search command - and I really don't want
to type in the "--verbose" every time.

If these types of changes continue, there will be no advantage in using wajig - it evolved as it is
for a reason. BEFORE changing things, it might be good to pass it by the folks that use it.


--------------------------------------------------------------------------------
Karl Schmidt EMail Ka...@xtronics.com
Transtronics, Inc. WEB http://secure.transtronics.com
3209 West 9th Street Ph (785) 841-3089
Lawrence, KS 66049 FAX (785) 841-0434

"Of course the people don't want war. But after all, it's the leaders of the country who determine
the policy, and it's always a simple matter to drag the people along whether it's a democracy, a
fascist dictatorship, or a parliament, or a communist dictatorship. Voice or no voice, the people
can always be brought to the bidding of the leaders. That is easy. All you have to do is tell them
they are being attacked, and denounce the pacifists for lack of patriotism, and exposing the country
to greater danger."
-- Herman Goering at the Nuremberg trials

--------------------------------------------------------------------------------

Tshepang Lekhonkhobe

unread,
Jul 17, 2012, 4:40:36 PM7/17/12
to wa...@googlegroups.com
On Tue, Jul 17, 2012 at 8:47 PM, Karl Schmidt <ka...@xtronics.com> wrote:
> On 07/17/2012 05:22 AM, Tshepang Lekhonkhobe wrote:
>>
>> Yeah, I did change it in late 2010, and no one complained, until now :)
>> Maybe wajig does not have
>> that many users, or maybe most just go away silently when something works
>> differently (i.e.
>> broken in their eyes).
>
>
> That it isn't in this form in the current stable is the only reason I
> haven't complained. I'm the
> guy that originally requested the feature as in:
>
> $ wajig listall seachterm
>
> It was to replace $ wajig listall |grep searchterm
>
> Which I found I typed several times a day.
>
> I think it is important to realize that wajig exists not only to provide
> orthogonality to the
> package interface, but to help with tasks that the people who use it
> actually do daily.
>
> Removing or changing these features wholesale is going to cause huge
> problems if it enters stable in
> this form. There are many scipts that call wajig.

Note that a change like this would not be accepted this time into
Wheezy, since it's a feature change, not a bugfix.

> If I want to search more than the one line I would use the search command -
> and I really don't want
> to type in the "--verbose" every time.

You can use "-v" instead :)

> If these types of changes continue, there will be no advantage in using
> wajig - it evolved as it is
> for a reason. BEFORE changing things, it might be good to pass it by the
> folks that use it.

That's the reason this mailing list was created... to avoid these
kinds of problems.

Karl Schmidt

unread,
Jul 18, 2012, 5:21:37 PM7/18/12
to wa...@googlegroups.com
On 07/17/2012 03:40 PM, Tshepang Lekhonkhobe wrote:

>
> Note that a change like this would not be accepted this time into
> Wheezy, since it's a feature change, not a bugfix.

It is definitely a bug fix as it un-breaks peoples scripts. (nice try )


>> If these types of changes continue, there will be no advantage in using
>> wajig - it evolved as it is
>> for a reason. BEFORE changing things, it might be good to pass it by the
>> folks that use it.
>
> That's the reason this mailing list was created... to avoid these
> kinds of problems.

I think that is why the "before" above is in caps. Adding features is one thing - changing things
that are used at the command line should wait for a bit of consensus first. I don't think I'm the
only one that has created a bunch of scripts that uses wajig..


--------------------------------------------------------------------------------
Karl Schmidt EMail Ka...@xtronics.com
Transtronics, Inc. WEB http://secure.transtronics.com
3209 West 9th Street Ph (785) 841-3089
Lawrence, KS 66049 FAX (785) 841-0434

Any cat would tell you that you can only wash one paw at a time;
while we try to do everything at once. -kps

--------------------------------------------------------------------------------

Tshepang Lekhonkhobe

unread,
Jul 18, 2012, 5:57:30 PM7/18/12
to wa...@googlegroups.com
On 18/07/2012 23:21, Karl Schmidt wrote:
> On 07/17/2012 03:40 PM, Tshepang Lekhonkhobe wrote:
>
>>
>> Note that a change like this would not be accepted this time into
>> Wheezy, since it's a feature change, not a bugfix.
>
> It is definitely a bug fix as it un-breaks peoples scripts. (nice try )

The specific issue that Reuben had is the changed output of bash
completion, so no script will break. Worry not sire.

>>> If these types of changes continue, there will be no advantage in using
>>> wajig - it evolved as it is
>>> for a reason. BEFORE changing things, it might be good to pass it by the
>>> folks that use it.
>>
>> That's the reason this mailing list was created... to avoid these
>> kinds of problems.
>
> I think that is why the "before" above is in caps. Adding features is
> one thing - changing things that are used at the command line should
> wait for a bit of consensus first. I don't think I'm the only one that
> has created a bunch of scripts that uses wajig..

Maybe you misunderstand. I meant that this mailing list was created to
ask people if it's okay to change things, so I don't later have people
complaining that I broke their scripts.
Reply all
Reply to author
Forward
0 new messages