[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#35790] [PATCH 1/2] lint: Move the linting code to a different modul

From: Ludovic Courtès
Subject: [bug#35790] [PATCH 1/2] lint: Move the linting code to a different module.
Date: Fri, 12 Jul 2019 16:36:44 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux)


I think this could have come as a subsequent patch, but regardless, this
is a welcome move.

Christopher Baines <address@hidden> skribis:

> To try and move towards making programatic access to the linting code easier,
> this commit separates out the linting script, from the linting functionality
> that it uses.

For the final version, please write a change log.

> +(define-module (guix lint)
> +  #:use-module ((guix store) #:hide (close-connection))
> +  #:use-module (guix base32)
> +  #:use-module (guix download)
> +  #:use-module (guix ftp-client)
> +  #:use-module (guix http-client)
> +  #:use-module (guix packages)
> +  #:use-module (guix licenses)
> +  #:use-module (guix records)
> +  #:use-module (guix grafts)
> +  #:use-module (guix ui)

The principle that’s mostly followed for Guix modules is that they are
UI-independent: they might throw ‘&message’ error conditions, they might
even use (guix i18n), but they usually don’t depend on (guix ui).

The idea is separation of concerns: the actual UI implementation details
(TUI, GUI, etc.) remain separate from the API.

At first sight (guix ui) is not necessary here, and it’s enough to use
(guix i18n), isn’t it?

Last thing: please add this new file to po/guix/

Thanks for working on it!


reply via email to

[Prev in Thread] Current Thread [Next in Thread]