all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: zimoun <zimon.toutoune@gmail.com>
To: Liliana Marie Prikler <liliana.prikler@gmail.com>
Cc: Guix Devel <guix-devel@gnu.org>
Subject: Re: guix show --bibtex (was: How to compute SWHID? (with Guix/Disarchive))
Date: Tue, 7 Dec 2021 18:39:18 +0100	[thread overview]
Message-ID: <CAJ3okZ0o5-uiTUX0TpLBiiA83RCfD8-SxM9ka=1bWyQFeogyng@mail.gmail.com> (raw)
In-Reply-To: <0c3f6f91b267f1d5f06fc427c1eca03660aba8b5.camel@gmail.com>

Hi,

On Tue, 7 Dec 2021 at 18:07, Liliana Marie Prikler
<liliana.prikler@gmail.com> wrote:

> Given that `guix show' output is well-structured (it uses the Recutils
> format), couldn't you post-process to form a bibtex file?  In
> particular, you could use recfmt IIUC.

Good idea.  For an trivial example,

--8<---------------cut here---------------start------------->8---
$ cat bibtex.tmpl
@example{ {{name}}@{{version}},
title      = {{name}},
url        = {{home-page}},
license    = {{license}},
abstract   = {{synopsis}},
swhid      = {swh:1:...},
repository = "WE HAVE THAT INFO",
author     = "?????",
date       = "?????",
}

$ guix show hello | recfmt -f bibtex.tmpl
@example{ hello@2.10,
title      = hello,
url        = 0.000000,
license    = GPL 3+,
abstract   = Hello, GNU world: An example GNU package  ,
swhid      = {swh:1:...},
repository = "WE HAVE THAT INFO",
author     = "?????",
date       = "?????",
}
--8<---------------cut here---------------end--------------->8---

However, 2 minor annoying comments:

 1. SWHID is not computed by "guix show".
 2. Typing the path to the template; aside recutils is not installed
by default, IIRC.

Well, #2 could be solved with something under ~/.config/guix/current/bin.

About #1, it requires some work and I am not convinced I would like
that Guix does it each time I call "guix show".

> That said, there would be stuff like author etc. missing from Guix'
> metadata.  What kind of output were you hoping to produce?

As much fields as possible.  As the example above more or less.  Well,
use bibtex-software as decribe here:

https://mirrors.chevalier.io/CTAN/macros/latex/contrib/biblatex-contrib/biblatex-software/software-biblatex.pdf


Cheers,
simon


  reply	other threads:[~2021-12-07 17:39 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-01 10:12 How to compute SWHID? (with Guix/Disarchive) zimoun
2021-12-06 12:43 ` Ludovic Courtès
2021-12-06 15:18   ` Timothy Sample
2021-12-07 17:07 ` guix show --bibtex (was: How to compute SWHID? (with Guix/Disarchive)) Liliana Marie Prikler
2021-12-07 17:39   ` zimoun [this message]
2021-12-07 18:20     ` Liliana Marie Prikler
2021-12-07 18:55       ` zimoun

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

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

  git send-email \
    --in-reply-to='CAJ3okZ0o5-uiTUX0TpLBiiA83RCfD8-SxM9ka=1bWyQFeogyng@mail.gmail.com' \
    --to=zimon.toutoune@gmail.com \
    --cc=guix-devel@gnu.org \
    --cc=liliana.prikler@gmail.com \
    /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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.