* [PATCH] Hack font.
@ 2016-06-06 20:33 Dmitry Nikolaev
2016-06-07 14:33 ` 宋文武
0 siblings, 1 reply; 2+ messages in thread
From: Dmitry Nikolaev @ 2016-06-06 20:33 UTC (permalink / raw)
To: guix-devel
[-- Attachment #1.1: Type: text/plain, Size: 75 bytes --]
I've added Hack font family to fonts.scm. Patch in the attachment.
Dmitry
[-- Attachment #1.2: Type: text/html, Size: 121 bytes --]
[-- Attachment #2: 0001-Add-Hack-font.patch --]
[-- Type: text/x-patch, Size: 3319 bytes --]
From 772fc5f4d5708188c3e863bff6486b8687e8bcd6 Mon Sep 17 00:00:00 2001
From: 8p8c <cameltheman@gmail.com>
Date: Mon, 6 Jun 2016 23:27:10 +0300
Subject: [PATCH] Add Hack font.
---
gnu/packages/fonts.scm | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 53 insertions(+)
diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm
index 893db56..3a0f68d 100644
--- a/gnu/packages/fonts.scm
+++ b/gnu/packages/fonts.scm
@@ -9,6 +9,7 @@
;;; Copyright © 2016 Nils Gillmann <niasterisk@grrlz.net>
;;; Copyright © 2016 Jookia <166291@gmail.com>
;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
+;;; Copyright © 2016 Dmitry Nikolaev <cameltheman@gmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -808,3 +809,55 @@ mind. The font includes a bold version and a good italic version with new
glyph designs, not just an added slant.")
(home-page "https://fontlibrary.org/en/font/fantasque-sans-mono")
(license license:silofl1.1)))
+
+(define-public font-hack
+ (package
+ (name "font-hack")
+ (version "2.020")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append
+ "https://github.com/chrissimpkins/Hack/releases/download/v"
+ version
+ "/Hack-v"
+ (string-replace-substring version "." "_")
+ "-ttf.zip"))
+ (sha256
+ (base32
+ "16kkmc3psckw1b7k07ccn1gi5ymhlg9djh43nqjzg065g6p6d184"))))
+ (build-system trivial-build-system)
+ (arguments
+ `(#:modules ((guix build utils))
+ #:builder (begin
+ (use-modules (guix build utils)
+ (srfi srfi-26))
+
+ (let ((PATH (string-append (assoc-ref %build-inputs
+ "unzip")
+ "/bin"))
+ (font-dir (string-append %output
+ "/share/fonts/truetype"))
+ (doc-dir (string-append %output "/share/doc/"
+ ,name "-" ,version)))
+ (setenv "PATH" PATH)
+ (system* "unzip" (assoc-ref %build-inputs "source"))
+
+ (mkdir-p font-dir)
+ (mkdir-p doc-dir)
+ (for-each (lambda (ttf)
+ (copy-file ttf
+ (string-append font-dir "/" ttf)))
+ (find-files "." "\\.ttf$"))
+ (for-each (lambda (doc)
+ (copy-file doc
+ (string-append doc-dir "/" doc)))
+ (find-files "." "\\.txt$"))))))
+ (native-inputs `(("source" ,source)
+ ("unzip" ,unzip)))
+ (home-page "https://sourcefoundry.org/hack/")
+ (synopsis "A typeface designed for sourcecode.")
+ (description "The Hack Font is designed for the screen.")
+ (license
+ (license:x11-style
+ "https://github.com/chrissimpkins/Hack/blob/master/LICENSE.md"
+ "Hack Open Font License v2.0"))))
--
2.7.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-06-07 14:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-06-06 20:33 [PATCH] Hack font Dmitry Nikolaev
2016-06-07 14:33 ` 宋文武
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.