summaryrefslogtreecommitdiff
path: root/guix/import/stackage.scm
diff options
context:
space:
mode:
authorTimothy Sample <samplet@ngyro.com>2020-11-03 15:30:28 -0500
committerTimothy Sample <samplet@ngyro.com>2020-11-21 22:11:36 -0500
commit464b1fffb0f08a452b4ee67ba23c87730d73568e (patch)
treee56ff4c08670df996ced3242f4528519c7996c52 /guix/import/stackage.scm
parenteeee65076e3199c778b177e06de3aae7696dbb9f (diff)
downloadguix-patches-464b1fffb0f08a452b4ee67ba23c87730d73568e.tar
guix-patches-464b1fffb0f08a452b4ee67ba23c87730d73568e.tar.gz
lint: Add 'check-haskell-stackage' checker.
* guix/lint.scm (check-haskell-stackage): New procedure. (%network-dependent-checkers): Add 'haskell-stackage' checker. * guix/import/hackage.scm (%hackage-url): New variable. (hackage-source-url, hackage-cabal-url): Use it in place of a hard-coded string. * guix/import/stackage.scm (%stackage-url): Make it a parameter. (stackage-lts-info-fetch): Update accordingly. * tests/lint.scm ("hackage-stackage"): New test.
Diffstat (limited to 'guix/import/stackage.scm')
-rw-r--r--guix/import/stackage.scm8
1 files changed, 5 insertions, 3 deletions
diff --git a/guix/import/stackage.scm b/guix/import/stackage.scm
index 93cf214127..77cc6350cb 100644
--- a/guix/import/stackage.scm
+++ b/guix/import/stackage.scm
@@ -30,7 +30,8 @@
#:use-module (guix memoization)
#:use-module (guix packages)
#:use-module (guix upstream)
- #:export (stackage->guix-package
+ #:export (%stackage-url
+ stackage->guix-package
stackage-recursive-import
%stackage-updater))
@@ -39,7 +40,8 @@
;;; Stackage info fetcher and access functions
;;;
-(define %stackage-url "https://www.stackage.org")
+(define %stackage-url
+ (make-parameter "https://www.stackage.org"))
;; Latest LTS version compatible with GHC 8.6.5.
(define %default-lts-version "14.27")
@@ -55,7 +57,7 @@
;; "Retrieve the information about the LTS Stackage release VERSION."
(memoize
(lambda* (#:optional (version ""))
- (let* ((url (string-append %stackage-url
+ (let* ((url (string-append (%stackage-url)
"/lts-" (if (string-null? version)
%default-lts-version
version)))