lunes, 28 de diciembre de 2015

Linting guix packages

Guix is getting more mature every day (It's probably going to beta soonish).  One of the commands it got 'recently' is guix lint.

Once you write a package definition you want to know if it complies with guix standards. Let's try guix lint.

  1. Write package definition.
  2. Put the definition into a guix checkout (not your running guix).
  3. run 'guix environment guix'.
  4. cd to the checkout directory.
  5. ./bootstrap && ./configure --localstatedir=/var --prefix= && make
  6. ./pre-inst-env guix lint my-package
  7.  If you get an 'ERROR: missing interface for module (gnutls)', means that you need to install gnutls. 'guix package -i gnutls'
  8. After that, you can finally run 'guix lint my-package', and it'll tell you if you have any obvious failures or warnings in your definition.