summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArun Isaac2023-01-22 23:11:43 +0000
committerArun Isaac2023-01-23 00:28:11 +0000
commit9e5b68ad2beef430618ae759758651b8cbfb7870 (patch)
tree4dac09cc66dfe294eb5504cabb128d77406940bb
parentd1df6854fb487ce42150e6c7c393279f1c4f0ab5 (diff)
downloadtissue-9e5b68ad2beef430618ae759758651b8cbfb7870.tar.gz
tissue-9e5b68ad2beef430618ae759758651b8cbfb7870.tar.lz
tissue-9e5b68ad2beef430618ae759758651b8cbfb7870.zip
guix.scm: Add font-ibm-plex as a development dependency.
We use font-ibm-plex on the tissue website. * guix.scm: Import font-ibm-plex from (gnu packages fonts) with the guix: prefix. Import (guix utils). (font-ibm-plex): New variable. (package)[native-inputs]: Add font-ibm-plex.
-rw-r--r--guix.scm29
1 files changed, 26 insertions, 3 deletions
diff --git a/guix.scm b/guix.scm
index 3dbad01..d1cd18e 100644
--- a/guix.scm
+++ b/guix.scm
@@ -1,5 +1,5 @@
;;; tissue --- Text based issue tracker
-;;; Copyright © 2022 Arun Isaac <arunisaac@systemreboot.net>
+;;; Copyright © 2022, 2023 Arun Isaac <arunisaac@systemreboot.net>
;;;
;;; This file is part of tissue.
;;;
@@ -17,6 +17,7 @@
;;; along with tissue. If not, see <https://www.gnu.org/licenses/>.
(use-modules ((gnu packages autotools) #:select (autoconf automake))
+ ((gnu packages fonts) #:select (font-ibm-plex) #:prefix guix:)
((gnu packages gettext) #:select (gnu-gettext))
((gnu packages guile) #:select (guile-3.0 guile-git))
((gnu packages guile-xyz) #:select (guile-filesystem guile-xapian))
@@ -25,7 +26,8 @@
(guix gexp)
(guix git-download)
((guix licenses) #:prefix license:)
- (guix packages))
+ (guix packages)
+ (guix utils))
(define %source-dir (dirname (current-filename)))
@@ -53,6 +55,23 @@
(prepend automake)
(prepend gnu-gettext))))))
+(define font-ibm-plex
+ (package
+ (inherit guix:font-ibm-plex)
+ (arguments
+ (substitute-keyword-arguments (package-arguments guix:font-ibm-plex)
+ ((#:phases phases #~%standard-phases)
+ #~(modify-phases #$phases
+ ;; Install the woff/woff2 web fonts instead of opentype
+ ;; and truetype fonts.
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out")))
+ (for-each (lambda (file)
+ (install-file file (string-append out "/share/fonts/web")))
+ (find-files (getcwd) "\\.(woff|woff2)$")))))))))))
+
+
(define tissue
(package
(name "tissue")
@@ -95,4 +114,8 @@
(description "tissue is a text based issue tracker.")
(license license:gpl3+)))
-tissue
+(package
+ (inherit tissue)
+ (native-inputs
+ (modify-inputs (package-native-inputs tissue)
+ (prepend font-ibm-plex))))