Commit | Line | Data |
---|---|---|
5d38aa08 MJ |
1 | ;;; GNU Guix --- Functional package management for GNU |
2 | ;;; Copyright © 2016 Matthew Jordan <matthewjordandevops@yandex.com> | |
3 | ;;; Copyright © 2016 Ludovic Courtès <ludo@gnu.org> | |
fbc70c97 | 4 | ;;; Copyright © 2019 Ricardo Wurmus <rekado@elephly.net> |
06effaf6 | 5 | ;;; Copyright © 2019 Tobias Geerinckx-Rice <me@tobias.gr> |
48970389 | 6 | ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net> |
5d38aa08 MJ |
7 | ;;; |
8 | ;;; This file is part of GNU Guix. | |
9 | ;;; | |
10 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
11 | ;;; under the terms of the GNU General Public License as published by | |
12 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
13 | ;;; your option) any later version. | |
14 | ;;; | |
15 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
16 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
17 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
18 | ;;; GNU General Public License for more details. | |
19 | ;;; | |
20 | ;;; You should have received a copy of the GNU General Public License | |
21 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
22 | ||
23 | (define-module (gnu packages entr) | |
48970389 | 24 | #:use-module (gnu packages ncurses) |
5d38aa08 MJ |
25 | #:use-module (guix licenses) |
26 | #:use-module (guix packages) | |
27 | #:use-module (guix download) | |
28 | #:use-module (guix build-system gnu)) | |
29 | ||
30 | (define-public entr | |
31 | (package | |
32 | (name "entr") | |
06effaf6 | 33 | (version "4.2") |
5d38aa08 MJ |
34 | (source (origin |
35 | (method url-fetch) | |
36 | (uri (string-append "http://entrproject.org/code/entr-" | |
37 | version ".tar.gz")) | |
38 | (sha256 | |
39 | (base32 | |
06effaf6 | 40 | "0w2xkf77jikcjh15fp9g7661ss30pz3jbnh261vqpaqavwah4c17")))) |
5d38aa08 MJ |
41 | (build-system gnu-build-system) |
42 | (arguments | |
43 | `(#:test-target "test" | |
fbc70c97 RW |
44 | #:phases |
45 | (modify-phases %standard-phases | |
46 | (replace 'configure | |
47 | (lambda* (#:key outputs #:allow-other-keys) | |
48 | (let ((out (assoc-ref outputs "out"))) | |
49 | (setenv "CONFIG_SHELL" (which "bash")) | |
50 | (setenv "CC" (which "gcc")) | |
51 | (setenv "DESTDIR" (string-append out "/")) | |
52 | (setenv "PREFIX" "") | |
53 | (setenv "MANPREFIX" "man") | |
54 | (invoke "./configure")))) | |
55 | (add-before 'build 'remove-fhs-file-names | |
56 | (lambda _ | |
fbc70c97 | 57 | (substitute* "entr.c" |
48970389 JK |
58 | (("/bin/sh") (which "sh")) |
59 | (("/bin/cat") (which "cat")) | |
60 | (("/usr/bin/clear") (which "clear"))) | |
fbc70c97 | 61 | #t))))) |
48970389 JK |
62 | ;; ncurses provides the `clear' binary |
63 | (inputs `(("ncurses" ,ncurses))) | |
5d38aa08 MJ |
64 | (home-page "http://entrproject.org/") |
65 | (synopsis "Run arbitrary commands when files change") | |
66 | (description | |
6247431b | 67 | "entr is a zero-configuration tool with no external build or run-time |
5d38aa08 MJ |
68 | dependencies. The interface to entr is not only minimal, it aims to be simple |
69 | enough to create a new category of ad hoc automation. These micro-tests | |
70 | reduce keystrokes, but more importantly they emphasize the utility of | |
71 | automated checks.") | |
72 | ||
73 | ;; Per 'LICENSE', portability code under missing/ is under BSD-2. | |
74 | (license isc))) |