[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Announcing emacs-guix-packaging
From: |
Pierre Neidhardt |
Subject: |
Re: Announcing emacs-guix-packaging |
Date: |
Fri, 13 Nov 2020 10:45:08 +0100 |
Hi!
On the one hand, I can only echo Ryan's experience, and I suppose the
experience of most of us: emacs-guix has been a bit broken for a while
now.
I believe it suffers from 2 main issues:
- Geiser is a strong dependency: everything depends from a well-working
Geiser REPL.
- Geiser 0.12 broke the REPL setup :(
- Geiser chokes on large outputs, which happens on any Guix build. So
you can't build anything with emacs-guix.
- Emacs-Guix uses private parts of Guix if I'm not mistaken. Since
these parts are prone to change, it breaks Emacs-Guix once in a while.
Finally, it seems that Emacs-Guix is mostly unmaintained now:
https://github.com/alezost/guix.el/issues/38#issuecomment-617718043
On the other hand, leveraging the actual Guix API is a saner approach
than parsing the output.
It's what I did in Nyxt:
https://github.com/atlas-engineer/nyxt/blob/2-pre-release-4/libraries/ospama/ospama-guix.lisp
It's fast, reliable, flexible, structured.
> On the other hand, I am interested in building out a formal API for
> tools to interface with Guix without having to depend on its internals
> or parse the output of its CLI commands. This could be a Guile API,
> although I picture json would be a better choice to support diverse
> tooling.
Guix already has a stable API that can be leveraged by any programming
language thanks to the `guix repl` command. This is what I'm doing in
Nyxt.
> For one example of what I'd want the API for, in my `guix-packaging-
> insert-input` command I need to get the list of available Guix packages,
> and then for the selected package I need to find its scheme symbol. The
> emacs-guix approach to those things is to reach into Guix internal data
> structures and read out that data, which doesn't deliver results in
> practice.
Maybe emacs-guix does not do it well, but `fold-packages` works well for
Nyxt in practice!
> I opt instead to parse the output of the CLI command `guix
> package -A ""` as a tsv, which works as long as Guix doesn't change its
> output, but that's not guaranteed either.
Indeed, I don't think this is the right approach :p
Let me know what you think!
Cheers!
--
Pierre Neidhardt
https://ambrevar.xyz/
signature.asc
Description: PGP signature
- Announcing emacs-guix-packaging, Ryan Prior, 2020/11/10
- Re: Announcing emacs-guix-packaging, Pierre Neidhardt, 2020/11/10
- Re: Announcing emacs-guix-packaging, Ludovic Courtès, 2020/11/12
- Re: Announcing emacs-guix-packaging, Ryan Prior, 2020/11/12
- Reviving Emacs-Guix, Ludovic Courtès, 2020/11/13
- Re: Reviving Emacs-Guix, John Soo, 2020/11/13
- Re: Reviving Emacs-Guix, zimoun, 2020/11/13
- Re: Reviving Emacs-Guix, Ludovic Courtès, 2020/11/16
- Re: Reviving Emacs-Guix, Pierre Neidhardt, 2020/11/14
- Re: Reviving Emacs-Guix, zimoun, 2020/11/14
- Re: Reviving Emacs-Guix, Pierre Neidhardt, 2020/11/14
- Re: Reviving Emacs-Guix, zimoun, 2020/11/14