unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
From: Philippe Veber <philippe.veber@gmail.com>
To: Tobias Geerinckx-Rice <me@tobias.gr>
Cc: help-guix@gnu.org
Subject: Re: List available versions of package.
Date: Tue, 11 Jun 2019 09:43:08 +0200	[thread overview]
Message-ID: <CAOOOohSzUezKvm=RO0bXRGH3m0eo2x0cOTvd--vARxWoqtceaQ@mail.gmail.com> (raw)
In-Reply-To: <87ftohqg9l.fsf@nckx>

Hello Tobias, and thanks a lot for your answer!

So as I understand it, the distribution at a given moment contains only a
few versions (often one), and not all that have been specified at some
point. For instance, with your command I obtain:

$ guix package --list-available=^bowtie$
bowtie 2.3.4.3 out gnu/packages/bioinformatics.scm:1505:2

while I could check on guix git log that there has been more versions of
this bowtie program :

$ git log packages/bioinformatics.scm | grep "gnu: bowtie"
    gnu: bowtie: Update to 2.3.4.3.
    gnu: bowtie: Use 'modify-phases'.
    gnu: bowtie: Update to 2.3.2.
    gnu: bowtie: Update to 2.2.9.
    gnu: bowtie: Update to 2.2.6.

My use case is to be able to run old versions of software (like you've
never heard that before, right ;o)?) so is it correct to think that I have
to write a manifest file and then use a :

guix environment --manifest bowtie_2.2.9.scm -- bowtie2 ...

?
If so, I'm not absolutely clear on the contents of the manifest file. I
tried to get inspiration from the section on "Inferiors" [0], and wrote
this:

%% bowtie_2.2.9.scm %%%%%%%%%%%%%
(use-modules (guix inferior) (guix channels)
             (srfi srfi-1))   ;for 'first'

(define channels
  ;; This is the old revision from which we want to
  ;; extract guile-json.
  (list (channel
         (name 'guix)
         (url "https://git.savannah.gnu.org/git/guix.git")
         (commit
          "2642231b39d2f642364e96222690afce7c986bb6"))))

(define inferior
  ;; An inferior representing the above revision.
  (inferior-for-channels channels))

(packages->manifest
 (list (first (lookup-inferior-packages inferior "bowtie"))))
%%%%%%%%%%%%%%%

but got the following result:

$ guix environment --manifest=bowtie_2.2.9.scm -- bowtie2 --version
Mise à jour du canal « guix » depuis le dépôt Git «
https://git.savannah.gnu.org/git/guix.git »...
ice-9/eval.scm:223:20: In procedure proc:
erreur : %guix-register-program : variable non liée
conseil : Auriez-vous oublié un `use-modules' ?

Sorry for the french translation, but I assume you got that a module is
missing (BTW, that might mean that the example given in the manual section
for inferiors is missing it too). So for now I'm stuck, any help will be
much appreciated!

Cheers,
  Philippe.






[0] https://www.gnu.org/software/guix/manual/en/guix.html#Inferiors



Le lun. 10 juin 2019 à 23:31, Tobias Geerinckx-Rice <me@tobias.gr> a écrit :

> Philippe,
>
> Philippe Veber wrote:
> > I'm getting started with guix, and so far it's been just fine.
>
> Welcome!
>
> > I would like to see all available versions for a given package.
> > Is there a command that would help me with that?
>
> There is:
>
>   $ guix package --list-available=^glibc$
>   glibc 2.25    out,debug,static
>   gnu/packages/base.scm:921:2
>   glibc 2.22    out,debug,static
>   gnu/packages/base.scm:980:2
>   …
>
> For easier interactive use, you can use the short option ‘-A’.
>
> Note that this option takes a regular expression as argument.
> That makes it powerful, but means you'll have to enclose the name
> in ‘^…$’ if you want to match one specific package.
>
> Kind regards,
>
> T G-R
>

  reply	other threads:[~2019-06-11  7:43 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-10 18:27 List available versions of package Philippe Veber
2019-06-10 21:31 ` Tobias Geerinckx-Rice
2019-06-11  7:43   ` Philippe Veber [this message]
2019-06-22 11:26     ` Philippe Veber
2019-06-22 19:08       ` Tobias Geerinckx-Rice
2019-06-26 18:32         ` Philippe Veber
2019-06-22 22:46       ` Ricardo Wurmus
2019-06-26 18:43         ` Philippe Veber
2019-06-26 20:25           ` Ricardo Wurmus
2019-06-30 11:50             ` Philippe Veber
2019-07-02 15:48         ` Leo Famulari

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAOOOohSzUezKvm=RO0bXRGH3m0eo2x0cOTvd--vARxWoqtceaQ@mail.gmail.com' \
    --to=philippe.veber@gmail.com \
    --cc=help-guix@gnu.org \
    --cc=me@tobias.gr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).