This commit adds the relevant tables and code to store lint warnings in the database. Currently, only lint checkers which don't require access to the network will be run, as this allows the processing to happen without network access. Also, this functionality won't work in older versions of Guix which don't expose the lint warnings in a compatible way.
15 lines
566 B
Scheme
15 lines
566 B
Scheme
(define-module (guix-data-service model lint-checker)
|
|
#:use-module (srfi srfi-1)
|
|
#:use-module (ice-9 match)
|
|
#:use-module (guix-data-service model utils)
|
|
#:export (lint-checkers->lint-checker-ids))
|
|
|
|
(define (lint-checkers->lint-checker-ids conn lint-checkers-data)
|
|
(insert-missing-data-and-return-all-ids
|
|
conn
|
|
"lint_checkers"
|
|
`((name . ,(lambda (value)
|
|
(quote-string (symbol->string value))))
|
|
(description . ,quote-string)
|
|
(network_dependent . ,value->sql-boolean))
|
|
lint-checkers-data))
|