gnu: git-annex: Update to 8.20200226.
[jackhill/guix/guix.git] / gnu / packages / haskell-apps.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015 Siniša Biđin <sinisa@bidin.eu>
3 ;;; Copyright © 2015, 2017, 2018 Ricardo Wurmus <rekado@elephly.net>
4 ;;; Copyright © 2016, 2017, 2018 ng0 <ng0@n0.is>
5 ;;; Copyright © 2017 Danny Milosavljevic <dannym@scratchpost.org>
6 ;;; Copyright © 2017, 2018 Alex Vong <alexvong1995@gmail.com>
7 ;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
8 ;;; Copyright © 2018 Timothy Sample <samplet@ngyro.com>
9 ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
10 ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
11 ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
12 ;;; Copyright © 2019 Kyle Meyer <kyle@kyleam.com>
13 ;;; Copyright © 2015 John Soo <jsoo1@asu.edu>
14 ;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il>
15 ;;; Copyright © 2019 Alex Griffin <a@ajgrf.com>
16 ;;;
17 ;;; This file is part of GNU Guix.
18 ;;;
19 ;;; GNU Guix is free software; you can redistribute it and/or modify it
20 ;;; under the terms of the GNU General Public License as published by
21 ;;; the Free Software Foundation; either version 3 of the License, or (at
22 ;;; your option) any later version.
23 ;;;
24 ;;; GNU Guix is distributed in the hope that it will be useful, but
25 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
26 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
27 ;;; GNU General Public License for more details.
28 ;;;
29 ;;; You should have received a copy of the GNU General Public License
30 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
31
32 (define-module (gnu packages haskell-apps)
33 #:use-module (guix download)
34 #:use-module (guix git-download)
35 #:use-module (guix packages)
36 #:use-module ((guix licenses) #:prefix license:)
37 #:use-module (guix build-system haskell)
38 #:use-module (gnu packages base)
39 #:use-module (gnu packages curl)
40 #:use-module (gnu packages gl)
41 #:use-module (gnu packages haskell)
42 #:use-module (gnu packages haskell-check)
43 #:use-module (gnu packages haskell-crypto)
44 #:use-module (gnu packages haskell-web)
45 #:use-module (gnu packages haskell-xyz)
46 #:use-module (gnu packages ncurses)
47 #:use-module (gnu packages perl)
48 #:use-module (gnu packages pkg-config)
49 #:use-module (gnu packages rsync)
50 #:use-module (gnu packages version-control))
51
52 ;; In Stackage LTS 14, this package is at 2.4.1.0. However, that
53 ;; version requires version 2.4.1.0 of the 'Cabal' package, which is
54 ;; provided by GHC 8.6.5 at version 2.4.0.1. Hence, we use an older
55 ;; version to match the compiler's library.
56 (define-public cabal-install
57 (package
58 (name "cabal-install")
59 (version "2.4.0.0")
60 (source
61 (origin
62 (method url-fetch)
63 (uri (string-append
64 "https://hackage.haskell.org/package/cabal-install/cabal-install-"
65 version
66 ".tar.gz"))
67 (sha256
68 (base32 "1xmyl0x8wqfrnray6ky5wy0g0samv4264fbdlzxhqsvk9dbfja8k"))))
69 (build-system haskell-build-system)
70 (arguments
71 `(#:cabal-revision
72 ("2" "1xil5pim6j1ckqj61zz6l7xpfxxr3rkw2hvpws2f7pr9shk645dl")
73 #:phases
74 (modify-phases %standard-phases
75 (add-before 'configure 'update-constraints
76 (lambda _
77 (substitute* "cabal-install.cabal"
78 (("zip-archive >= 0\\.3\\.2\\.5 && < 0\\.4,")
79 "zip-archive >= 0.3.2.5 && <= 0.4.1,"))
80 #t)))))
81 (inputs
82 `(("ghc-async" ,ghc-async)
83 ("ghc-base16-bytestring" ,ghc-base16-bytestring)
84 ("ghc-cryptohash-sha256" ,ghc-cryptohash-sha256)
85 ("ghc-echo" ,ghc-echo)
86 ("ghc-edit-distance" ,ghc-edit-distance)
87 ("ghc-hackage-security" ,ghc-hackage-security)
88 ("ghc-hashable" ,ghc-hashable)
89 ("ghc-http" ,ghc-http)
90 ("ghc-network-uri" ,ghc-network-uri)
91 ("ghc-network" ,ghc-network)
92 ("ghc-random" ,ghc-random)
93 ("ghc-resolv" ,ghc-resolv)
94 ("ghc-tar" ,ghc-tar)
95 ("ghc-zip-archive" ,ghc-zip-archive)
96 ("ghc-zlib" ,ghc-zlib)))
97 (home-page "https://www.haskell.org/cabal/")
98 (synopsis "Command-line interface for Cabal and Hackage")
99 (description
100 "The cabal command-line program simplifies the process of managing
101 Haskell software by automating the fetching, configuration, compilation and
102 installation of Haskell libraries and programs.")
103 (license license:bsd-3)))
104
105 (define-public corrode
106 (let ((commit "b6699fb2fa552a07c6091276285a44133e5c9789"))
107 (package
108 (name "corrode")
109 (version (string-append "0.0.1-" (string-take commit 7)))
110 (source
111 (origin
112 (method git-fetch)
113 (uri (git-reference
114 (url "https://github.com/jameysharp/corrode.git")
115 (commit "b6699fb2fa552a07c6091276285a44133e5c9789")))
116 (file-name (git-file-name name version))
117 (sha256
118 (base32 "02v0yyj6sk4gpg2222wzsdqjxn8w66scbnf6b20x0kbmc69qcz4r"))))
119 (build-system haskell-build-system)
120 (inputs
121 `(("ghc-language-c" ,ghc-language-c)
122 ("ghc-markdown-unlit" ,ghc-markdown-unlit)))
123 (home-page "https://github.com/jameysharp/corrode")
124 (synopsis "Automatic semantics-preserving translation from C to Rust")
125 (description
126 "This program reads a C source file and prints an equivalent module in
127 Rust syntax. It is intended to be useful for two different purposes:
128
129 @enumerate
130 @item Partial automation for migrating legacy code that was implemented in C.
131 @item A new, complementary approach to static analysis for C programs.
132 @end enumerate\n")
133 (license license:gpl2+))))
134
135 (define-public cpphs
136 (package
137 (name "cpphs")
138 (version "1.20.8")
139 (source
140 (origin
141 (method url-fetch)
142 (uri (string-append
143 "https://hackage.haskell.org/package/" name "/"
144 name "-" version ".tar.gz"))
145 (sha256
146 (base32
147 "1bh524asqhk9v1s0wvipl0hgn7l63iy3js867yv0z3h5v2kn8vg5"))))
148 (build-system haskell-build-system)
149 (inputs
150 `(("ghc-polyparse" ,ghc-polyparse)
151 ("ghc-old-locale" ,ghc-old-locale)
152 ("ghc-old-time" ,ghc-old-time)))
153 (home-page "http://projects.haskell.org/cpphs/")
154 (synopsis "Liberalised re-implementation of cpp, the C pre-processor")
155 (description "Cpphs is a re-implementation of the C pre-processor that is
156 both more compatible with Haskell, and itself written in Haskell so that it
157 can be distributed with compilers. This version of the C pre-processor is
158 pretty-much feature-complete and compatible with traditional (K&R)
159 pre-processors. Additional features include: a plain-text mode; an option to
160 unlit literate code files; and an option to turn off macro-expansion.")
161 (license (list license:lgpl2.1+ license:gpl3+))))
162
163 ;; Darcs has no https support: http://irclog.perlgeek.de/darcs/2016-09-17
164 ;; http://darcs.net/manual/Configuring_darcs.html#SECTION00440070000000000000
165 ;; and results of search engines will show that if the protocol is http, https
166 ;; is never mentioned.
167 (define-public darcs
168 (package
169 (name "darcs")
170 (version "2.14.2")
171 (source
172 (origin
173 (method url-fetch)
174 (uri (string-append "https://hackage.haskell.org/package/darcs/"
175 "darcs-" version ".tar.gz"))
176 (sha256
177 (base32
178 "0zm2486gyhiga1amclbg92cd09bvki6vgh0ll75hv5kl72j61lb5"))
179 (modules '((guix build utils)))
180 ;; Remove time-dependent code for reproducibility.
181 (snippet
182 '(begin
183 (substitute* "darcs/darcs.hs"
184 (("__DATE__") "\"1970-01-01\"")
185 (("__TIME__") "\"00:00:00\""))
186 #t))))
187 (build-system haskell-build-system)
188 (arguments
189 `(#:cabal-revision
190 ("1" "0xl7j5cm704pbl2ms0dkydh7jvrz0ym76d725ifpg4h902m1zkhg")
191 #:configure-flags '("-fpkgconfig" "-fcurl" "-flibiconv" "-fthreaded"
192 "-fnetwork-uri" "-fhttp" "--flag=executable"
193 "--flag=library")
194 #:phases
195 (modify-phases %standard-phases
196 (add-after 'patch-source-shebangs 'patch-sh
197 (lambda _
198 (substitute* "tests/issue538.sh"
199 (("/bin/sh") (which "sh")))
200 #t))
201 (add-before 'configure 'update-constraints
202 (lambda _
203 (substitute* "darcs.cabal"
204 (("QuickCheck >= 2\\.8\\.2 && < 2\\.13,")
205 "QuickCheck >= 2.8.2 && < 2.14,"))
206 #t)))))
207 (inputs
208 `(("ghc-cmdargs" ,ghc-cmdargs)
209 ("ghc-split" ,ghc-split)
210 ("ghc-test-framework-quickcheck2" ,ghc-test-framework-quickcheck2)
211 ("ghc-test-framework-hunit" ,ghc-test-framework-hunit)
212 ("ghc-test-framework" ,ghc-test-framework)
213 ("ghc-quickcheck" ,ghc-quickcheck)
214 ("ghc-findbin" ,ghc-findbin)
215 ("ghc-hunit" ,ghc-hunit)
216 ("ghc-async" ,ghc-async)
217 ("ghc-attoparsec" ,ghc-attoparsec)
218 ("ghc-base16-bytestring" ,ghc-base16-bytestring)
219 ("ghc-bytestring-builder" ,ghc-bytestring-builder)
220 ("ghc-cryptohash" ,ghc-cryptohash)
221 ("ghc-data-ordlist" ,ghc-data-ordlist)
222 ("ghc-fgl" ,ghc-fgl)
223 ("ghc-system-filepath" ,ghc-system-filepath)
224 ("ghc-graphviz" ,ghc-graphviz)
225 ("ghc-hashable" ,ghc-hashable)
226 ("ghc-html" ,ghc-html)
227 ("ghc-mmap" ,ghc-mmap)
228 ("ghc-old-time" ,ghc-old-time)
229 ("ghc-random" ,ghc-random)
230 ("ghc-regex-applicative" ,ghc-regex-applicative)
231 ("ghc-regex-compat-tdfa" ,ghc-regex-compat-tdfa)
232 ("ghc-sandi" ,ghc-sandi)
233 ("ghc-shelly" ,ghc-shelly)
234 ("ghc-tar" ,ghc-tar)
235 ("ghc-transformers-compat" ,ghc-transformers-compat)
236 ("ghc-unix-compat" ,ghc-unix-compat)
237 ("ghc-utf8-string" ,ghc-utf8-string)
238 ("ghc-vector" ,ghc-vector)
239 ("ghc-zip-archive" ,ghc-zip-archive)
240 ("ghc-zlib" ,ghc-zlib)
241 ("ghc-http" ,ghc-http)
242 ("curl" ,curl)
243 ("ghc" ,ghc)
244 ("ncurses" ,ncurses)
245 ("perl" ,perl)
246 ("libiconv" ,libiconv)
247 ("ghc-network" ,ghc-network)
248 ("ghc-network-uri" ,ghc-network-uri)))
249 (native-inputs
250 `(("pkg-config" ,pkg-config)))
251 (home-page "http://darcs.net")
252 (synopsis "Distributed Revision Control System")
253 (description
254 "Darcs is a revision control system. It is:
255
256 @enumerate
257 @item Distributed: Every user has access to the full command set, removing boundaries
258 between server and client or committer and non-committers.
259 @item Interactive: Darcs is easy to learn and efficient to use because it asks you
260 questions in response to simple commands, giving you choices in your work flow.
261 You can choose to record one change in a file, while ignoring another. As you update
262 from upstream, you can review each patch name, even the full diff for interesting
263 patches.
264 @item Smart: Originally developed by physicist David Roundy, darcs is based on a
265 unique algebra of patches called @url{http://darcs.net/Theory,Patchtheory}.
266 @end enumerate")
267 (license license:gpl2)))
268
269 (define-public git-annex
270 (package
271 (name "git-annex")
272 (version "8.20200226")
273 (source
274 (origin
275 (method url-fetch)
276 (uri (string-append "https://hackage.haskell.org/package/"
277 "git-annex/git-annex-" version ".tar.gz"))
278 (sha256
279 (base32 "09v80ni1w9z1im79lzrnpz7xlivwna44zqpwq4axwyd17cffqi9m"))))
280 (build-system haskell-build-system)
281 (arguments
282 `(#:configure-flags
283 '("--flags=-Android -Assistant -Pairing -Webapp -WebDAV")
284 #:phases
285 (modify-phases %standard-phases
286 (add-before 'configure 'patch-shell-for-tests
287 (lambda _
288 ;; Shell.hs defines "/bin/sh" that is used in Git hooks. We
289 ;; shouldn't patch hooks with Guix's current bash because the
290 ;; hooks can exist after that bash is garbage collected, but
291 ;; let's temporarily patch it so that we can run the tests.
292 (copy-file "Utility/Shell.hs" "/tmp/Shell.hs")
293 (substitute* "Utility/Shell.hs"
294 (("/bin/sh") (which "sh")))
295 #t))
296 (add-before 'configure 'factor-setup
297 (lambda _
298 ;; Factor out necessary build logic from the provided
299 ;; `Setup.hs' script. The script as-is does not work because
300 ;; it cannot find its dependencies, and there is no obvious way
301 ;; to tell it where to look. Note that we do not preserve the
302 ;; code that installs man pages here.
303 (call-with-output-file "PreConf.hs"
304 (lambda (out)
305 (format out "import qualified Build.Configure as Configure~%")
306 (format out "main = Configure.run Configure.tests~%")))
307 (call-with-output-file "Setup.hs"
308 (lambda (out)
309 (format out "import Distribution.Simple~%")
310 (format out "main = defaultMain~%")))
311 #t))
312 (add-before 'configure 'pre-configure
313 (lambda _
314 (invoke "runhaskell" "PreConf.hs")
315 #t))
316 (replace 'check
317 (lambda _
318 ;; We need to set the path so that Git recognizes
319 ;; `git annex' as a custom command.
320 (setenv "PATH" (string-append (getenv "PATH") ":"
321 (getcwd) "/dist/build/git-annex"))
322 (with-directory-excursion "dist/build/git-annex"
323 (symlink "git-annex" "git-annex-shell"))
324 (invoke "git-annex" "test")
325 #t))
326 (add-after 'check 'unpatch-shell-and-rebuild
327 (lambda args
328 ;; Undo `patch-shell-for-tests'.
329 (copy-file "/tmp/Shell.hs" "Utility/Shell.hs")
330 (apply (assoc-ref %standard-phases 'build) args)))
331 (add-after 'install 'install-symlinks
332 (lambda* (#:key outputs #:allow-other-keys)
333 (let* ((out (assoc-ref outputs "out"))
334 (bin (string-append out "/bin")))
335 (symlink (string-append bin "/git-annex")
336 (string-append bin "/git-annex-shell"))
337 (symlink (string-append bin "/git-annex")
338 (string-append bin "/git-remote-tor-annex"))
339 #t))))))
340 (inputs
341 `(("curl" ,curl)
342 ("ghc-aeson" ,ghc-aeson)
343 ("ghc-async" ,ghc-async)
344 ("ghc-aws" ,ghc-aws)
345 ("ghc-bloomfilter" ,ghc-bloomfilter)
346 ("ghc-byteable" ,ghc-byteable)
347 ("ghc-case-insensitive" ,ghc-case-insensitive)
348 ("ghc-concurrent-output" ,ghc-concurrent-output)
349 ("ghc-crypto-api" ,ghc-crypto-api)
350 ("ghc-cryptonite" ,ghc-cryptonite)
351 ("ghc-data-default" ,ghc-data-default)
352 ("ghc-disk-free-space" ,ghc-disk-free-space)
353 ("ghc-dlist" ,ghc-dlist)
354 ("ghc-edit-distance" ,ghc-edit-distance)
355 ("ghc-esqueleto" ,ghc-esqueleto)
356 ("ghc-exceptions" ,ghc-exceptions)
357 ("ghc-feed" ,ghc-feed)
358 ("ghc-filepath-bytestring" ,ghc-filepath-bytestring)
359 ("ghc-free" ,ghc-free)
360 ("ghc-hslogger" ,ghc-hslogger)
361 ("ghc-http-client" ,ghc-http-client)
362 ("ghc-http-conduit" ,ghc-http-conduit)
363 ("ghc-http-types" ,ghc-http-types)
364 ("ghc-ifelse" ,ghc-ifelse)
365 ("ghc-magic" ,ghc-magic)
366 ("ghc-memory" ,ghc-memory)
367 ("ghc-monad-control" ,ghc-monad-control)
368 ("ghc-monad-logger" ,ghc-monad-logger)
369 ("ghc-network" ,ghc-network)
370 ("ghc-old-locale" ,ghc-old-locale)
371 ("ghc-optparse-applicative" ,ghc-optparse-applicative)
372 ("ghc-persistent" ,ghc-persistent)
373 ("ghc-persistent-sqlite" ,ghc-persistent-sqlite)
374 ("ghc-persistent-template" ,ghc-persistent-template)
375 ("ghc-quickcheck" ,ghc-quickcheck)
376 ("ghc-random" ,ghc-random)
377 ("ghc-regex-tdfa" ,ghc-regex-tdfa)
378 ("ghc-resourcet" ,ghc-resourcet)
379 ("ghc-safesemaphore" ,ghc-safesemaphore)
380 ("ghc-sandi" ,ghc-sandi)
381 ("ghc-securemem" ,ghc-securemem)
382 ("ghc-socks" ,ghc-socks)
383 ("ghc-split" ,ghc-split)
384 ("ghc-stm-chans" ,ghc-stm-chans)
385 ("ghc-tagsoup" ,ghc-tagsoup)
386 ("ghc-unix-compat" ,ghc-unix-compat)
387 ("ghc-unordered-containers" ,ghc-unordered-containers)
388 ("ghc-utf8-string" ,ghc-utf8-string)
389 ("ghc-uuid" ,ghc-uuid)
390 ("git" ,git)
391 ("rsync" ,rsync)))
392 (native-inputs
393 `(("ghc-tasty" ,ghc-tasty)
394 ("ghc-tasty-hunit" ,ghc-tasty-hunit)
395 ("ghc-tasty-quickcheck" ,ghc-tasty-quickcheck)
396 ("ghc-tasty-rerun" ,ghc-tasty-rerun)))
397 (home-page "https://git-annex.branchable.com/")
398 (synopsis "Manage files with Git, without checking in their contents")
399 (description "This package allows managing files with Git, without
400 checking the file contents into Git. It can store files in many places,
401 such as local hard drives and cloud storage services. It can also be
402 used to keep a folder in sync between computers.")
403 ;; The main author has released all his changes under AGPLv3+ as of March
404 ;; 2019 (7.20190219-187-g40ecf58d4). These are also licensed under the
405 ;; original GPLv3+ license, but going forward new changes will be under
406 ;; only AGPLv3+. The other licenses below cover code written by others.
407 ;; See git-annex's COPYRIGHT file for details on each file.
408 (license (list license:agpl3+
409 license:gpl3+
410 license:bsd-2
411 license:expat
412 license:gpl2))))
413
414 (define-public hlint
415 (package
416 (name "hlint")
417 (version "2.1.26")
418 (source
419 (origin
420 (method url-fetch)
421 (uri (string-append
422 "https://hackage.haskell.org/package/" name
423 "/" name "-" version ".tar.gz"))
424 (sha256
425 (base32
426 "16zkkpbfrd69853cdqf597fva969lirfc86b039i9zd7ghlrcayc"))))
427 (build-system haskell-build-system)
428 (inputs
429 `(("cpphs" ,cpphs)
430 ("ghc-unordered-containers" ,ghc-unordered-containers)
431 ("ghc-yaml" ,ghc-yaml)
432 ("ghc-vector" ,ghc-vector)
433 ("ghc-data-default" ,ghc-data-default)
434 ("ghc-cmdargs" ,ghc-cmdargs)
435 ("ghc-haskell-src-exts" ,ghc-haskell-src-exts)
436 ("ghc-haskell-src-exts-util" ,ghc-haskell-src-exts-util)
437 ("ghc-uniplate" ,ghc-uniplate)
438 ("ghc-ansi-terminal" ,ghc-ansi-terminal)
439 ("ghc-extra" ,ghc-extra)
440 ("ghc-refact" ,ghc-refact)
441 ("ghc-aeson" ,ghc-aeson)
442 ("ghc-lib-parser" ,ghc-lib-parser)
443 ("hscolour" ,hscolour)))
444 (home-page "https://github.com/ndmitchell/hlint")
445 (synopsis "Suggest improvements for Haskell source code")
446 (description "HLint reads Haskell programs and suggests changes that
447 hopefully make them easier to read. HLint also makes it easy to disable
448 unwanted suggestions, and to add your own custom suggestions.")
449 (license license:bsd-3)))
450
451 (define-public hoogle
452 (package
453 (name "hoogle")
454 (version "5.0.17.11")
455 (source
456 (origin
457 (method url-fetch)
458 (uri
459 (string-append
460 "https://hackage.haskell.org/package/hoogle/hoogle-"
461 version ".tar.gz"))
462 (sha256
463 (base32
464 "1svp8z9pad8z2j386pr0dda0ds8ddxab0salnz4gm51q877w93p1"))))
465 (build-system haskell-build-system)
466 (inputs
467 `(("ghc-quickcheck" ,ghc-quickcheck)
468 ("ghc-aeson" ,ghc-aeson)
469 ("ghc-blaze-html" ,ghc-blaze-html)
470 ("ghc-blaze-markup" ,ghc-blaze-markup)
471 ("ghc-cmdargs" ,ghc-cmdargs)
472 ("ghc-conduit" ,ghc-conduit)
473 ("ghc-conduit-extra" ,ghc-conduit-extra)
474 ("ghc-connection" ,ghc-connection)
475 ("ghc-extra" ,ghc-extra)
476 ("ghc-foundation" ,ghc-foundation)
477 ("ghc-old-locale" ,ghc-old-locale)
478 ("ghc-haskell-src-exts" ,ghc-haskell-src-exts)
479 ("ghc-http-conduit" ,ghc-http-conduit)
480 ("ghc-http-types" ,ghc-http-types)
481 ("ghc-js-flot" ,ghc-js-flot)
482 ("ghc-js-jquery" ,ghc-js-jquery)
483 ("ghc-mmap" ,ghc-mmap)
484 ("ghc-process-extras" ,ghc-process-extras)
485 ("ghc-resourcet" ,ghc-resourcet)
486 ("ghc-storable-tuple" ,ghc-storable-tuple)
487 ("ghc-tar" ,ghc-tar)
488 ("ghc-uniplate" ,ghc-uniplate)
489 ("ghc-utf8-string" ,ghc-utf8-string)
490 ("ghc-vector" ,ghc-vector)
491 ("ghc-wai" ,ghc-wai)
492 ("ghc-wai-logger" ,ghc-wai-logger)
493 ("ghc-warp" ,ghc-warp)
494 ("ghc-warp-tls" ,ghc-warp-tls)
495 ("ghc-zlib" ,ghc-zlib)))
496 (home-page "https://hoogle.haskell.org/")
497 (synopsis "Haskell API Search")
498 (description "Hoogle is a Haskell API search engine, which allows
499 you to search many standard Haskell libraries by either function name,
500 or by approximate type signature.")
501 (license license:bsd-3)))
502
503 (define-public hscolour
504 (package
505 (name "hscolour")
506 (version "1.24.4")
507 (source
508 (origin
509 (method url-fetch)
510 (uri (string-append
511 "https://hackage.haskell.org/package/hscolour/hscolour-"
512 version
513 ".tar.gz"))
514 (sha256
515 (base32
516 "079jwph4bwllfp03yfr26s5zc6m6kw3nhb1cggrifh99haq34cr4"))))
517 (build-system haskell-build-system)
518 (home-page "https://hackage.haskell.org/package/hscolour")
519 (synopsis "Script to colourise Haskell code")
520 (description "HSColour is a small Haskell script to colourise Haskell
521 code. It currently has six output formats: ANSI terminal codes (optionally
522 XTerm-256colour codes), HTML 3.2 with font tags, HTML 4.01 with CSS, HTML 4.01
523 with CSS and mouseover annotations, XHTML 1.0 with inline CSS styling, LaTeX,
524 and mIRC chat codes.")
525 (license license:bsd-3)))
526
527 (define-public kmonad
528 (package
529 (name "kmonad")
530 (version "0.3.0")
531 (source
532 (origin
533 (method git-fetch)
534 (uri (git-reference
535 (url "https://github.com/david-janssen/kmonad.git")
536 (commit version)))
537 (file-name (git-file-name name version))
538 (sha256
539 (base32 "1g40nkpldih6h1rlxjx5yf9iavr3qs1f2b6j0gd8135p5hkg8d8n"))))
540 (build-system haskell-build-system)
541 (arguments
542 `(#:phases
543 (modify-phases %standard-phases
544 (delete 'haddock) ; Haddock fails to generate docs
545 (add-after 'install 'install-udev-rules
546 (lambda* (#:key outputs #:allow-other-keys)
547 (let* ((out (assoc-ref outputs "out"))
548 (rules (string-append out "/lib/udev/rules.d")))
549 (mkdir-p rules)
550 (call-with-output-file (string-append rules "/70-kmonad.rules")
551 (lambda (port)
552 (display
553 (string-append
554 "KERNEL==\"uinput\", MODE=\"0660\", "
555 "GROUP=\"input\", OPTIONS+=\"static_node=uinput\"\n")
556 port)))
557 #t)))
558 (add-after 'install-udev-rules 'install-documentation
559 (lambda* (#:key outputs #:allow-other-keys)
560 (let* ((out (assoc-ref outputs "out"))
561 (doc (string-append out "/share/doc/kmonad-" ,version)))
562 (install-file "README.md" doc)
563 (copy-recursively "doc" doc)
564 (copy-recursively "example" (string-append doc "/example"))
565 #t))))))
566 (inputs
567 `(("ghc-cereal" ,ghc-cereal)
568 ("ghc-exceptions" ,ghc-exceptions)
569 ("ghc-hashable" ,ghc-hashable)
570 ("ghc-lens" ,ghc-lens)
571 ("ghc-megaparsec" ,ghc-megaparsec)
572 ("ghc-optparse-applicative" ,ghc-optparse-applicative)
573 ("ghc-unagi-chan" ,ghc-unagi-chan)
574 ("ghc-unliftio" ,ghc-unliftio)
575 ("ghc-unordered-containers" ,ghc-unordered-containers)))
576 (home-page "https://github.com/david-janssen/kmonad")
577 (synopsis "Advanced keyboard manager")
578 (description "KMonad is a keyboard remapping utility that supports
579 advanced functionality, such as custom keymap layers and modifiers, macros,
580 and conditional mappings that send a different keycode when tapped or held.
581 By operating at a lower level than most similar tools, it supports X11,
582 Wayland, and Linux console environments alike.")
583 (license license:expat)))
584
585 (define-public raincat
586 (package
587 (name "raincat")
588 (version "1.2.1")
589 (source
590 (origin
591 (method url-fetch)
592 (uri (string-append "mirror://hackage/package/Raincat/"
593 "Raincat-" version ".tar.gz"))
594 (sha256
595 (base32
596 "10y9zi22m6hf13c9h8zd9vg7mljpwbw0r3djb6r80bna701fdf6c"))))
597 (build-system haskell-build-system)
598 (arguments
599 `(#:phases
600 (modify-phases %standard-phases
601 (add-after 'install 'wrap-executable
602 (lambda* (#:key inputs outputs #:allow-other-keys)
603 (let ((out (assoc-ref outputs "out")))
604 (wrap-program (string-append out "/bin/raincat")
605 `("LD_LIBRARY_PATH" ":" =
606 (,(string-append (assoc-ref inputs "freeglut")
607 "/lib"))))
608 #t))))))
609 (inputs
610 `(("ghc-extensible-exceptions" ,ghc-extensible-exceptions)
611 ("ghc-random" ,ghc-random)
612 ("ghc-glut" ,ghc-glut)
613 ("freeglut" ,freeglut)
614 ("ghc-opengl" ,ghc-opengl)
615 ("ghc-sdl2" ,ghc-sdl2)
616 ("ghc-sdl2-image" ,ghc-sdl2-image)
617 ("ghc-sdl2-mixer" ,ghc-sdl2-mixer)))
618 (home-page "http://www.bysusanlin.com/raincat/")
619 (synopsis "Puzzle game with a cat in lead role")
620 (description "Project Raincat is a game developed by Carnegie Mellon
621 students through GCS during the Fall 2008 semester. Raincat features game
622 play inspired from classics Lemmings and The Incredible Machine. The project
623 proved to be an excellent learning experience for the programmers. Everything
624 is programmed in Haskell.")
625 (license license:bsd-3)))
626
627 (define-public scroll
628 (package
629 (name "scroll")
630 (version "1.20180421")
631 (source
632 (origin
633 (method url-fetch)
634 (uri (string-append
635 "https://hackage.haskell.org/package/scroll/scroll-"
636 version ".tar.gz"))
637 (sha256
638 (base32
639 "0apzrvf99rskj4dbmn57jjxrsf19j436s8a09m950df5aws3a0wj"))))
640 (build-system haskell-build-system)
641 (inputs
642 `(("ghc-case-insensitive" ,ghc-case-insensitive)
643 ("ghc-data-default" ,ghc-data-default)
644 ("ghc-ifelse" ,ghc-ifelse)
645 ("ghc-monad-loops" ,ghc-monad-loops)
646 ("ghc-ncurses" ,ghc-ncurses)
647 ("ghc-optparse-applicative" ,ghc-optparse-applicative)
648 ("ghc-random" ,ghc-random)
649 ("ghc-vector" ,ghc-vector)))
650 (home-page "https://joeyh.name/code/scroll/")
651 (synopsis "scroll(6), a roguelike game")
652 (description
653 "You're a bookworm that's stuck on a scroll. You have to dodge between
654 words and use spells to make your way down the page as the scroll is read. Go
655 too slow and you'll get wound up in the scroll and crushed.")
656 (license license:gpl2)))
657
658 (define-public shellcheck
659 (package
660 (name "shellcheck")
661 (version "0.7.0")
662 (source
663 (origin
664 (method url-fetch)
665 (uri (string-append
666 "https://hackage.haskell.org/package/ShellCheck/ShellCheck-"
667 version ".tar.gz"))
668 (sha256
669 (base32 "1vx895cp5k5h0680xfwj74lk97m9y627n965x6srds0gfnbkzy9s"))
670 (file-name (string-append name "-" version ".tar.gz"))))
671 (build-system haskell-build-system)
672 (inputs
673 `(("ghc-aeson" ,ghc-aeson)
674 ("ghc-diff" ,ghc-diff)
675 ("ghc-quickcheck" ,ghc-quickcheck)
676 ("ghc-regex-tdfa" ,ghc-regex-tdfa)))
677 (home-page "https://github.com/koalaman/shellcheck")
678 (synopsis "Static analysis for shell scripts")
679 (description "@code{shellcheck} provides static analysis for
680 @command{bash} and @command{sh} shell scripts.
681 It gives warnings and suggestions in order to:
682
683 @enumerate
684 @item Point out and clarify typical beginner's syntax issues that cause
685 a shell to give cryptic error messages.
686 @item Point out and clarify typical intermediate level semantic problems
687 that cause a shell to behave strangely and counter-intuitively.
688 @item Point out subtle caveats, corner cases and pitfalls that may cause an
689 advanced user's otherwise working script to fail under future circumstances.
690 @end enumerate")
691 (license license:gpl3+)))
692
693 (define-public stylish-haskell
694 (package
695 (name "stylish-haskell")
696 (version "0.9.2.2")
697 (source
698 (origin
699 (method url-fetch)
700 (uri
701 (string-append
702 "mirror://hackage/package/stylish-haskell/"
703 "stylish-haskell-" version ".tar.gz"))
704 (sha256
705 (base32
706 "1zs624xqp6j8vrl6pfv18dm8vz8hvz25grri65ximxhcizgwhnax"))))
707 (build-system haskell-build-system)
708 (inputs
709 `(("ghc-aeson" ,ghc-aeson)
710 ("ghc-file-embed" ,ghc-file-embed)
711 ("ghc-haskell-src-exts" ,ghc-haskell-src-exts)
712 ("ghc-semigroups" ,ghc-semigroups)
713 ("ghc-syb" ,ghc-syb)
714 ("ghc-yaml" ,ghc-yaml)
715 ("ghc-strict" ,ghc-strict)
716 ("ghc-optparse-applicative" ,ghc-optparse-applicative)
717 ("ghc-hunit" ,ghc-hunit)
718 ("ghc-test-framework" ,ghc-test-framework)
719 ("ghc-test-framework-hunit" ,ghc-test-framework-hunit)))
720 (home-page "https://github.com/jaspervdj/stylish-haskell")
721 (synopsis "Haskell code prettifier")
722 (description
723 "A simple Haskell code prettifier. The goal is not to format all of the
724 code in a file, just clean up import statements and a few other tedious
725 items. This tool tries to help where necessary without getting in the way.")
726 (license license:bsd-3)))