Support storing whether to authenticate commits by git repository

To allow using the Guix Data Service when commits aren't authenticated.
This commit is contained in:
Christopher Baines 2020-10-07 18:50:13 +01:00
parent 888d9fcb98
commit 9f9c23010e
6 changed files with 30 additions and 4 deletions

View file

@ -47,12 +47,15 @@
(define (select-git-repository conn id)
(match (exec-query
conn
"SELECT label, url, cgit_url_base FROM git_repositories WHERE id = $1"
"SELECT label, url, cgit_url_base, fetch_with_authentication FROM git_repositories WHERE id = $1"
(list id))
(()
#f)
((result)
result)))
(((label url cgit_url_base fetch_with_authentication))
(list label
url
cgit_url_base
(string=? fetch_with_authentication "t")))))
(define (git-repository-id->url conn id)
(match