unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
* Commit of currently installed package?
@ 2022-01-04 15:12 t
  2022-01-04 17:42 ` zimoun
  0 siblings, 1 reply; 2+ messages in thread
From: t @ 2022-01-04 15:12 UTC (permalink / raw)
  To: help-guix

Hi guix.

Is there a way to find which commit the installed package came 
from. So that I could, for instance, `guix shell` this exact 
package. Specific case where I'm at a loss is this.

At one point I installed emacs-next --with-branch=master. Well, 
I've no clue what that master was pointing at at the time. I find 
myself in the situation where current upstream master appears 
subtly broken, but my local install is fine. But how do I get my 
currently installed emacs-next version run inside `guix shell` or 
`guix shell --container`?

--export-manifest is approximate and doesn't even give package 
  versions. Even if I start playing games with --export-channels 
  or Scheme %current-profile => manifest => lookup in inferior 
  that would still find whatever guix repo commit had for 
  emacs-next, not what I actually have installed.

Does guix track that sort of provenance for me to extract?

Thanks


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Commit of currently installed package?
  2022-01-04 15:12 Commit of currently installed package? t
@ 2022-01-04 17:42 ` zimoun
  0 siblings, 0 replies; 2+ messages in thread
From: zimoun @ 2022-01-04 17:42 UTC (permalink / raw)
  To: t; +Cc: help-guix

Hi,

On Tue, 4 Jan 2022 at 17:02, <t@fullmeta.me> wrote:

> At one point I installed emacs-next --with-branch=master. Well,

[...]

> --export-manifest is approximate and doesn't even give package
>   versions. Even if I start playing games with --export-channels
>   or Scheme %current-profile => manifest => lookup in inferior
>   that would still find whatever guix repo commit had for
>   emacs-next, not what I actually have installed.

No, you cannot know.  Well, that information is not stored by Guix,
AFAIK.  Indeed, it could nice, instead of the current "guix package
--export-manifest":

--8<---------------cut here---------------start------------->8---
(use-modules (guix transformations))

(define transform1
  (options->transformation
    '((with-branch . "emacs-next=master"))))

(packages->manifest
  (list (transform1
          (specification->package "emacs-next"))))
--8<---------------cut here---------------end--------------->8---

To replace 'master' by the commit used.

As a workaround, if it is recent enough (not removed by
last-expiry-cleanup ;-)), the temporary Emacs checkout could be still
there. :-)  Give a look at ~/.cache/guix/checkouts/ and probably
5buqmtmwqjycqg4thcbrvijjn74pijwvjy7ueikyoln7r7d7q6kq.


Hope that helps,
simon


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-01-04 17:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-04 15:12 Commit of currently installed package? t
2022-01-04 17:42 ` zimoun

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).