Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #223710 > unrolled thread

CLI interface to packages.debian.org

Started byIhor Antonov <ihor@antonovs.family>
First post2020-06-20 10:40 +0200
Last post2020-06-21 08:10 +0200
Articles 13 — 7 participants

Back to article view | Back to linux.debian.user


Contents

  CLI interface to packages.debian.org Ihor Antonov <ihor@antonovs.family> - 2020-06-20 10:40 +0200
    Re: CLI interface to packages.debian.org l0f4r0@tuta.io - 2020-06-20 11:10 +0200
      Re: CLI interface to packages.debian.org <tomas@tuxteam.de> - 2020-06-20 11:30 +0200
        Re: CLI interface to packages.debian.org Ihor Antonov <ihor@antonovs.family> - 2020-06-20 23:10 +0200
    Re: CLI interface to packages.debian.org Roberto C. Sánchez <roberto@debian.org> - 2020-06-20 13:20 +0200
      Re: CLI interface to packages.debian.org Jude DaShiell <jdashiel@panix.com> - 2020-06-20 17:10 +0200
        Re: CLI interface to packages.debian.org Ihor Antonov <ihor@antonovs.family> - 2020-06-20 23:10 +0200
          Re: CLI interface to packages.debian.org Roberto C. Sánchez <roberto@debian.org> - 2020-06-21 01:00 +0200
            Re: CLI interface to packages.debian.org Andrei POPESCU <andreimpopescu@gmail.com> - 2020-06-21 08:00 +0200
          Re: CLI interface to packages.debian.org Jude DaShiell <jdashiel@panix.com> - 2020-06-21 03:10 +0200
    Re: CLI interface to packages.debian.org John Hasler <jhasler@newsguy.com> - 2020-06-20 14:40 +0200
      Re: CLI interface to packages.debian.org Ihor Antonov <ihor@antonovs.family> - 2020-06-20 23:10 +0200
        Re: CLI interface to packages.debian.org Andrei POPESCU <andreimpopescu@gmail.com> - 2020-06-21 08:10 +0200

#223710 — CLI interface to packages.debian.org

FromIhor Antonov <ihor@antonovs.family>
Date2020-06-20 10:40 +0200
SubjectCLI interface to packages.debian.org
Message-ID<AjHcC-5EC-5@gated-at.bofh.it>

[Multipart message — attachments visible in raw view] — view raw

Hello everyone,

I often use https://packages.debian.org to look up package information.
I often search for binary and source packages, across various releases

I wish there was a way to do it without using a web browser. Is there some 
sort of CLI interface to packages.debian org?

Or maybe I need to add *everything* to my /etc/apt/sources.list ?

Any recommendations are appreciated.

Thanks
-- 
Ihor Antonov

[toc] | [next] | [standalone]


#223711

Froml0f4r0@tuta.io
Date2020-06-20 11:10 +0200
Message-ID<AjHFD-63U-1@gated-at.bofh.it>
In reply to#223710
Hi,

20 juin 2020 à 10:29 de ihor@antonovs.family:

> I often use https://packages.debian.org to look up package information.
> I often search for binary and source packages, across various releases
>
> I wish there was a way to do it without using a web browser. Is there some 
> sort of CLI interface to packages.debian org?
>
> Or maybe I need to add *everything* to my /etc/apt/sources.list ?
>
> Any recommendations are appreciated.
>
Mostly via:
* apt[-cache] search [-n] my_term
* apt showsrc my_package
* apt-file search my_file
* apt-file show my_package
* dpkg -S my_installed_file
* dpkg -L my_installed_package

However, those apt commands search  on your configured repositories (and dpkg looks only into what has been installed).
I don't think it would be a good idea to add all other repositories just to be able to include them in your searches. There would be too many side-effects regarding the maintainability of your system.
Or maybe inside an isolated environment otherwise...?

Best regards,
l0f4r0

[toc] | [prev] | [next] | [standalone]


#223714

From<tomas@tuxteam.de>
Date2020-06-20 11:30 +0200
Message-ID<AjHYZ-6aq-9@gated-at.bofh.it>
In reply to#223711

[Multipart message — attachments visible in raw view] — view raw

On Sat, Jun 20, 2020 at 11:05:41AM +0200, l0f4r0@tuta.io wrote:
> Hi,
> 
> 20 juin 2020 à 10:29 de ihor@antonovs.family:
> 
> > I often use https://packages.debian.org to look up package information.
> > I often search for binary and source packages, across various releases
> >
> > I wish there was a way to do it without using a web browser. Is there some 
> > sort of CLI interface to packages.debian org?

What is your aim: to search offline or to avoid the browser?

> > Or maybe I need to add *everything* to my /etc/apt/sources.list ?
> >
> > Any recommendations are appreciated.
> >
> Mostly via:
> * apt[-cache] search [-n] my_term
> * apt showsrc my_package
> * apt-file search my_file
> * apt-file show my_package
> * dpkg -S my_installed_file
> * dpkg -L my_installed_package
> 
> However, those apt commands search  on your configured repositories

...with the exception of apt-file (it defaults to your current
distro/arch, but you can override that).

Cheers
-- t

[toc] | [prev] | [next] | [standalone]


#223773

FromIhor Antonov <ihor@antonovs.family>
Date2020-06-20 23:10 +0200
Message-ID<AjSUq-4m7-9@gated-at.bofh.it>
In reply to#223714

[Multipart message — attachments visible in raw view] — view raw

On Saturday, 20 June 2020 02:20:59 PDT tomas@tuxteam.de wrote:
> On Sat, Jun 20, 2020 at 11:05:41AM +0200, l0f4r0@tuta.io wrote:
> > Hi,
> > 
> > 20 juin 2020 à 10:29 de ihor@antonovs.family:
> > > I often use https://packages.debian.org to look up package information.
> > > I often search for binary and source packages, across various releases
> > > 
> > > I wish there was a way to do it without using a web browser. Is there
> > > some
> > > sort of CLI interface to packages.debian org?
> 
> What is your aim: to search offline or to avoid the browser?

Avoid browser primarily. Offline would be a cherry on the cake, but I realize 
that such an offline database would go out of date quickly for Sid and 
Bullseye. 



-- 
Ihor Antonov

[toc] | [prev] | [next] | [standalone]


#223718

FromRoberto C. Sánchez <roberto@debian.org>
Date2020-06-20 13:20 +0200
Message-ID<AjJHr-7f9-3@gated-at.bofh.it>
In reply to#223710
On Sat, Jun 20, 2020 at 01:29:47AM -0700, Ihor Antonov wrote:
> Hello everyone,
> 
> I often use https://packages.debian.org to look up package information.
> I often search for binary and source packages, across various releases
> 
> I wish there was a way to do it without using a web browser. Is there some 
> sort of CLI interface to packages.debian org?
> 
> Or maybe I need to add *everything* to my /etc/apt/sources.list ?
> 
> Any recommendations are appreciated.
> 
There is not a direct CLI interface to packages.debian.org.  However,
the rmadison tool queries the same source data that powers
packages.debian.org.  That will probably do everything you need.

Regards,

-Roberto

-- 
Roberto C. Sánchez

[toc] | [prev] | [next] | [standalone]


#223736

FromJude DaShiell <jdashiel@panix.com>
Date2020-06-20 17:10 +0200
Message-ID<AjNi1-ZO-11@gated-at.bofh.it>
In reply to#223718
Another possibility may be one of the surfraw packages once configured
correctly.  Lots of other search possibilities in surfraw too.  Once
installed and configured read up on the -elvi in surfraw to find what
search possibilities you have.



--

[toc] | [prev] | [next] | [standalone]


#223772

FromIhor Antonov <ihor@antonovs.family>
Date2020-06-20 23:10 +0200
Message-ID<AjSUq-4m7-7@gated-at.bofh.it>
In reply to#223736

[Multipart message — attachments visible in raw view] — view raw

On Saturday, 20 June 2020 08:05:04 PDT Jude DaShiell wrote:
> Another possibility may be one of the surfraw packages once configured
> correctly.  Lots of other search possibilities in surfraw too.  Once
> installed and configured read up on the -elvi in surfraw to find what
> search possibilities you have.
> 
> 
> 
> --

Thanks for suggestions. I haven't heard anything about both of the mentioned 
tools:
- ramdison
- surfraw

Can you recommend any tutorials/wiki pages/blogs to get up to speed quickly?

Thanks

-- 
Ihor Antonov

[toc] | [prev] | [next] | [standalone]


#223783

FromRoberto C. Sánchez <roberto@debian.org>
Date2020-06-21 01:00 +0200
Message-ID<AjUCR-5bA-1@gated-at.bofh.it>
In reply to#223772
On Sat, Jun 20, 2020 at 02:07:59PM -0700, Ihor Antonov wrote:
> On Saturday, 20 June 2020 08:05:04 PDT Jude DaShiell wrote:
> > Another possibility may be one of the surfraw packages once configured
> > correctly.  Lots of other search possibilities in surfraw too.  Once
> > installed and configured read up on the -elvi in surfraw to find what
> > search possibilities you have.
> > 
> > 
> > 
> > --
> 
> Thanks for suggestions. I haven't heard anything about both of the mentioned 
> tools:
> - ramdison
> - surfraw
> 
> Can you recommend any tutorials/wiki pages/blogs to get up to speed quickly?
> 
sudo apt-get install devscripts
man rmadison

-- 
Roberto C. Sánchez

[toc] | [prev] | [next] | [standalone]


#223802

FromAndrei POPESCU <andreimpopescu@gmail.com>
Date2020-06-21 08:00 +0200
Message-ID<Ak1bk-M4-7@gated-at.bofh.it>
In reply to#223783

[Multipart message — attachments visible in raw view] — view raw

On Sb, 20 iun 20, 18:53:50, Roberto C. Sánchez wrote:
> On Sat, Jun 20, 2020 at 02:07:59PM -0700, Ihor Antonov wrote:
> > On Saturday, 20 June 2020 08:05:04 PDT Jude DaShiell wrote:
> > > Another possibility may be one of the surfraw packages once configured
> > > correctly.  Lots of other search possibilities in surfraw too.  Once
> > > installed and configured read up on the -elvi in surfraw to find what
> > > search possibilities you have.
> > > 
> > > 
> > > 
> > > --
> > 
> > Thanks for suggestions. I haven't heard anything about both of the mentioned 
> > tools:
> > - ramdison
> > - surfraw
> > 
> > Can you recommend any tutorials/wiki pages/blogs to get up to speed quickly?
> > 
> sudo apt-get install devscripts

This is probably better for most users (as opposed to Debian 
Developers):

    apt install devscripts liburi-perl wget --no-install-recommends
    (or 'curl' instead of 'wget')

The package 'devscripts' is...  special ;)
(read the description for details)

Kind regards,
Andrei
-- 
http://wiki.debian.org/FAQsFromDebianUser

[toc] | [prev] | [next] | [standalone]


#223791

FromJude DaShiell <jdashiel@panix.com>
Date2020-06-21 03:10 +0200
Message-ID<AjWEF-6AB-1@gated-at.bofh.it>
In reply to#223772
No, what I did with surfraw got done by reading the man pages.  The
other tool, I've never heard of before either.

On Sat, 20 Jun 2020, Ihor Antonov wrote:

> Date: Sat, 20 Jun 2020 17:07:59
> From: Ihor Antonov <ihor@antonovs.family>
> To: debian-user@lists.debian.org
> Subject: Re: CLI interface to packages.debian.org
>
> On Saturday, 20 June 2020 08:05:04 PDT Jude DaShiell wrote:
> > Another possibility may be one of the surfraw packages once configured
> > correctly.  Lots of other search possibilities in surfraw too.  Once
> > installed and configured read up on the -elvi in surfraw to find what
> > search possibilities you have.
> >
> >
> >
> > --
>
> Thanks for suggestions. I haven't heard anything about both of the mentioned
> tools:
> - ramdison
> - surfraw
>
> Can you recommend any tutorials/wiki pages/blogs to get up to speed quickly?
>
> Thanks
>
>

-- 

[toc] | [prev] | [next] | [standalone]


#223722

FromJohn Hasler <jhasler@newsguy.com>
Date2020-06-20 14:40 +0200
Message-ID<AjKWR-7UK-11@gated-at.bofh.it>
In reply to#223710
Ihor writes:
> I wish there was a way to do it without using a web browser. Is there
> some sort of CLI interface to packages.debian org?

Do you specifically require a command line interface, or just a text
one?  They are not the same thing.  If the latter use a text browser
such as Lynx.  If the former perhaps the -c and/or -o options for
apt-cache might be interesting.
-- 
John Hasler 
jhasler@newsguy.com
Elmwood, WI USA

[toc] | [prev] | [next] | [standalone]


#223771

FromIhor Antonov <ihor@antonovs.family>
Date2020-06-20 23:10 +0200
Message-ID<AjSUq-4m7-5@gated-at.bofh.it>
In reply to#223722

[Multipart message — attachments visible in raw view] — view raw

On Saturday, 20 June 2020 05:32:41 PDT John Hasler wrote:
> Ihor writes:
> > I wish there was a way to do it without using a web browser. Is there
> > some sort of CLI interface to packages.debian org?
> 
> Do you specifically require a command line interface, or just a text
> one?  They are not the same thing.  If the latter use a text browser
> such as Lynx.  If the former perhaps the -c and/or -o options for
> apt-cache might be interesting.

I want some sort of API, something I can potentially automate.
Lynx does not really fit that requirement. If anything, I'd rather do it with 
curl.. but this is too low level.


-- 
Ihor Antonov

[toc] | [prev] | [next] | [standalone]


#223803

FromAndrei POPESCU <andreimpopescu@gmail.com>
Date2020-06-21 08:10 +0200
Message-ID<Ak1l0-14x-7@gated-at.bofh.it>
In reply to#223771

[Multipart message — attachments visible in raw view] — view raw

On Sb, 20 iun 20, 14:05:22, Ihor Antonov wrote:
> On Saturday, 20 June 2020 05:32:41 PDT John Hasler wrote:
> > Ihor writes:
> > > I wish there was a way to do it without using a web browser. Is there
> > > some sort of CLI interface to packages.debian org?
> > 
> > Do you specifically require a command line interface, or just a text
> > one?  They are not the same thing.  If the latter use a text browser
> > such as Lynx.  If the former perhaps the -c and/or -o options for
> > apt-cache might be interesting.
> 
> I want some sort of API, something I can potentially automate.
> Lynx does not really fit that requirement. If anything, I'd rather do it with 
> curl.. but this is too low level.

In order of suitability and complexity, as far as I understood your 
needs:

1. rmadison
2. apt-file
3. APT ('apt cache' or 'apt-cache'), by adding sources for all releases 
you are interested in (pinned to -1 if necessary).

Kind regards,
Andrei
-- 
http://wiki.debian.org/FAQsFromDebianUser

[toc] | [prev] | [standalone]


Back to top | Article view | linux.debian.user


csiph-web