gnu: Add agate.
[jackhill/guix/guix.git] / gnu / packages / rust-apps.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2019, 2020 John Soo <jsoo1@asu.edu>
3 ;;; Copyright © 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
4 ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
5 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
6 ;;; Copyright © 2020 Leo Famulari <leo@famulari.name>
7 ;;; Copyright © 2020 Mark H Weaver <mhw@netris.org>
8 ;;; Copyright © 2020 Gabriel Arazas <foo.dogsquared@gmail.com>
9 ;;; Copyright © 2020, 2021 Nicolas Goaziou <mail@nicolasgoaziou.fr>
10 ;;; Copyright © 2021 Tobias Geerinckx-Rice <me@tobias.gr>
11 ;;; Copyright © 2021 Sharlatan Hellseher <sharlatanus@gmail.ccom>
12 ;;; Copyright © 2021 Zheng Junjie <873216071@qq.com>
13 ;;; Copyright © 2021 Alexandru-Sergiu Marton <brown121407@posteo.ro>
14 ;;;
15 ;;; This file is part of GNU Guix.
16 ;;;
17 ;;; GNU Guix is free software; you can redistribute it and/or modify it
18 ;;; under the terms of the GNU General Public License as published by
19 ;;; the Free Software Foundation; either version 3 of the License, or (at
20 ;;; your option) any later version.
21 ;;;
22 ;;; GNU Guix is distributed in the hope that it will be useful, but
23 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
24 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 ;;; GNU General Public License for more details.
26 ;;;
27 ;;; You should have received a copy of the GNU General Public License
28 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
29
30 (define-module (gnu packages rust-apps)
31 #:use-module ((guix licenses) #:prefix license:)
32 #:use-module (guix build-system cargo)
33 #:use-module (guix download)
34 #:use-module (guix packages)
35 #:use-module (gnu packages compression)
36 #:use-module (gnu packages crates-io)
37 #:use-module (gnu packages crates-graphics)
38 #:use-module (gnu packages documentation)
39 #:use-module (gnu packages fontutils)
40 #:use-module (gnu packages gtk)
41 #:use-module (gnu packages jemalloc)
42 #:use-module (gnu packages pcre)
43 #:use-module (gnu packages pkg-config)
44 #:use-module (gnu packages tls)
45 #:use-module (gnu packages version-control))
46
47 (define-public agate
48 (package
49 (name "agate")
50 (version "2.5.2")
51 (source
52 (origin
53 (method url-fetch)
54 (uri (crate-uri "agate" version))
55 (file-name (string-append name "-" version ".tar.gz"))
56 (sha256
57 (base32 "1mhrl4j5r6wzsnwpqsbgzny5vqschyjm3gnk4y88har7skk7j19v"))))
58 (build-system cargo-build-system)
59 (arguments
60 `(#:cargo-inputs
61 (("rust-configparser" ,rust-configparser-2)
62 ("rust-env-logger" ,rust-env-logger-0.8)
63 ("rust-getopts" ,rust-getopts-0.2)
64 ("rust-glob" ,rust-glob-0.3)
65 ("rust-log" ,rust-log-0.4)
66 ("rust-mime-guess" ,rust-mime-guess-2)
67 ("rust-once-cell" ,rust-once-cell-1)
68 ("rust-percent-encoding" ,rust-percent-encoding-2)
69 ("rust-rustls" ,rust-rustls-0.19)
70 ("rust-tokio" ,rust-tokio-1)
71 ("rust-tokio-rustls" ,rust-tokio-rustls-0.22)
72 ("rust-url" ,rust-url-2))))
73 (home-page "https://github.com/mbrubeck/agate")
74 (synopsis "Very simple server for the Gemini hypertext protocol")
75 (description
76 "Agate is a server for the Gemini network protocol, built with the Rust
77 programming language. It has very few features, and can only serve static
78 files. It uses async I/O, and should be quite efficient even when running on
79 low-end hardware and serving many concurrent requests.")
80 (license (list license:expat license:asl2.0))))
81
82 (define-public bat
83 (package
84 (name "bat")
85 (version "0.17.1")
86 (source
87 (origin
88 (method url-fetch)
89 (uri (crate-uri "bat" version))
90 (file-name (string-append name "-" version ".tar.gz"))
91 (sha256
92 (base32 "1ia12774prjnm3msiaja6qdpxkpyknxswqpgkmwzj0wn9nhkc7nz"))))
93 (build-system cargo-build-system)
94 (arguments
95 `(#:cargo-inputs
96 (("rust-ansi-colours" ,rust-ansi-colours-1)
97 ("rust-ansi-term" ,rust-ansi-term-0.12)
98 ("rust-atty" ,rust-atty-0.2)
99 ("rust-clap" ,rust-clap-2)
100 ("rust-console" ,rust-console-0.13)
101 ("rust-content-inspector" ,rust-content-inspector-0.2)
102 ("rust-dirs" ,rust-dirs-3)
103 ("rust-encoding" ,rust-encoding-0.2)
104 ("rust-error-chain" ,rust-error-chain-0.12)
105 ("rust-git2" ,rust-git2-0.13)
106 ("rust-globset" ,rust-globset-0.4)
107 ("rust-lazy-static" ,rust-lazy-static-1)
108 ("rust-path-abs" ,rust-path-abs-0.5)
109 ("rust-semver" ,rust-semver-0.11)
110 ("rust-serde" ,rust-serde-1)
111 ("rust-serde-yaml" ,rust-serde-yaml-0.8)
112 ("rust-shell-words" ,rust-shell-words-1)
113 ("rust-syntect" ,rust-syntect-4)
114 ("rust-unicode-width" ,rust-unicode-width-0.1)
115 ("rust-wild" ,rust-wild-2))
116 #:cargo-development-inputs
117 (("rust-assert-cmd" ,rust-assert-cmd-1)
118 ("rust-predicates" ,rust-predicates-1)
119 ("rust-tempdir" ,rust-tempdir-0.3))))
120 (native-inputs
121 `(("pkg-config" ,pkg-config)))
122 (inputs
123 `(("libgit2" ,libgit2)
124 ("zlib" ,zlib)))
125 (home-page "https://github.com/sharkdp/bat")
126 (synopsis "@command{cat} clone with syntax highlighting and git integration")
127 (description
128 "@command{bat} is a drop-in @command{cat} replacement featuring syntax
129 highlighting for a large number of languages, git integration, and automatic
130 paging.")
131 (license (list license:expat license:asl2.0))))
132
133 (define-public drill
134 (package
135 (name "drill")
136 (version "0.7.1")
137 (source
138 (origin
139 (method url-fetch)
140 (uri (crate-uri "drill" version))
141 (file-name (string-append name "-" version ".tar.gz"))
142 (sha256
143 (base32 "1m73d7rzi0p5c1hn0081d2235kcyapdza7h0vqf5jhnirpnjn793"))))
144 (build-system cargo-build-system)
145 (arguments
146 `(#:cargo-inputs
147 (("rust-async-trait" ,rust-async-trait-0.1)
148 ("rust-clap" ,rust-clap-2)
149 ("rust-colored" ,rust-colored-1)
150 ("rust-csv" ,rust-csv-1)
151 ("rust-futures" ,rust-futures-0.3)
152 ("rust-lazy-static" ,rust-lazy-static-1)
153 ("rust-linked-hash-map" ,rust-linked-hash-map-0.5)
154 ("rust-num-cpus" ,rust-num-cpus-1)
155 ("rust-rand" ,rust-rand-0.7)
156 ("rust-regex" ,rust-regex-1)
157 ("rust-reqwest" ,rust-reqwest-0.10)
158 ("rust-serde" ,rust-serde-1)
159 ("rust-serde-json" ,rust-serde-json-1)
160 ("rust-tokio" ,rust-tokio-0.2)
161 ("rust-url" ,rust-url-2)
162 ("rust-yaml-rust" ,rust-yaml-rust-0.4))))
163 (native-inputs
164 `(("pkg-config" ,pkg-config)))
165 (inputs
166 `(("openssl" ,openssl)))
167 (home-page "https://github.com/fcsonline/drill")
168 (synopsis "HTTP load testing application")
169 (description
170 "Drill is a HTTP load testing application written in Rust inspired by
171 Ansible syntax. Benchmark files can be written in YAML.")
172 (license license:gpl3)))
173
174 (define-public exa
175 (package
176 (name "exa")
177 (version "0.9.0")
178 (source
179 (origin
180 (method url-fetch)
181 (uri (crate-uri "exa" version))
182 (file-name
183 (string-append name "-" version ".tar.gz"))
184 (sha256
185 (base32
186 "1s902xgplz1167k0r7x235p914lprpsqy2if0kpa1mlb0fswqqq4"))))
187 (build-system cargo-build-system)
188 (arguments
189 `(#:cargo-inputs
190 (("rust-ansi-term" ,rust-ansi-term-0.12)
191 ("rust-datetime" ,rust-datetime-0.4)
192 ("rust-env-logger" ,rust-env-logger-0.6)
193 ("rust-git2" ,rust-git2-0.9)
194 ("rust-glob" ,rust-glob-0.3)
195 ("rust-lazy-static" ,rust-lazy-static-1)
196 ("rust-libc" ,rust-libc-0.2)
197 ("rust-locale" ,rust-locale-0.2)
198 ("rust-log" ,rust-log-0.4)
199 ("rust-natord" ,rust-natord-1)
200 ("rust-num-cpus" ,rust-num-cpus-1)
201 ("rust-number-prefix" ,rust-number-prefix-0.3)
202 ("rust-scoped-threadpool" ,rust-scoped-threadpool-0.1)
203 ("rust-term-grid" ,rust-term-grid-0.1)
204 ("rust-term-size" ,rust-term-size-0.3)
205 ("rust-unicode-width" ,rust-unicode-width-0.1)
206 ("rust-users" ,rust-users-0.9)
207 ("rust-zoneinfo-compiled" ,rust-zoneinfo-compiled-0.4))
208 #:cargo-development-inputs
209 (("rust-datetime" ,rust-datetime-0.4))
210 #:phases
211 (modify-phases %standard-phases
212 ;; Ignoring failing tests.
213 ;; Reported in https://github.com/ogham/exa/issues/318
214 (add-before 'check 'disable-failing-tests
215 (lambda _
216 (substitute* "src/options/mod.rs"
217 (("^.*fn oneline_across.*" oneline-across)
218 (string-append "#[ignore]\n" oneline-across)))
219
220 (substitute* "src/options/view.rs"
221 (("test!\\(across:.*") "")
222 (("test!\\(cr:.*") "")
223 (("test!\\(empty:.*") "")
224 (("test!\\(gracross:.*") "")
225 (("test!\\(grid:.*") "")
226 (("test!\\(icons:.*") "")
227 (("test!\\(just_binary:.*") "")
228 (("test!\\(just_blocks:.*") "")
229 (("test!\\(just_bytes:.*") "")
230 (("test!\\(just_git:.*") "")
231 (("test!\\(just_group:.*") "")
232 (("test!\\(just_header:.*") "")
233 (("test!\\(just_inode:.*") "")
234 (("test!\\(just_links:.*") "")
235 (("test!\\(leg:.*") "")
236 (("test!\\(lid:.*") "")
237 (("test!\\(original_g:.*") ""))
238 #t))
239 (add-after 'install 'install-extras
240 (lambda* (#:key outputs #:allow-other-keys)
241 (let* ((out (assoc-ref outputs "out"))
242 (share (string-append out "/share"))
243 (man1 (string-append share "/man/man1")))
244 (install-file "contrib/man/exa.1" man1)
245 (mkdir-p (string-append out "/etc/bash_completion.d"))
246 (mkdir-p (string-append share "/fish/vendor_completions.d"))
247 (mkdir-p (string-append share "/zsh/site-functions"))
248 (copy-file "contrib/completions.bash"
249 (string-append out "/etc/bash_completion.d/exa"))
250 (copy-file "contrib/completions.fish"
251 (string-append share "/fish/vendor_completions.d/exa.fish"))
252 (copy-file "contrib/completions.zsh"
253 (string-append share "/zsh/site-functions/_exa"))
254 #t))))))
255 (inputs
256 `(("libgit2" ,libgit2)
257 ("zlib" ,zlib)))
258 (native-inputs
259 `(("pkg-config" ,pkg-config)))
260 (home-page "https://the.exa.website/")
261 (synopsis "Modern replacement for ls")
262 (description "@code{exa} is a modern replacement for the command-line
263 program @code{ls}. It uses colours to distinguish file types and metadata. It
264 also knows about symlinks, extended attributes, and Git.")
265 (license license:expat)))
266
267 (define-public fd
268 (package
269 (name "fd")
270 (version "8.1.1")
271 (source
272 (origin
273 (method url-fetch)
274 (uri (crate-uri "fd-find" version))
275 (file-name
276 (string-append name "-" version ".tar.gz"))
277 (sha256
278 (base32
279 "124a5r8hpk2phs1288jybh34d48yxy44wr7gv5ggchs272gs2jam"))))
280 (build-system cargo-build-system)
281 (arguments
282 `(#:cargo-inputs
283 (("rust-ansi-term" ,rust-ansi-term-0.12)
284 ("rust-anyhow" ,rust-anyhow-1)
285 ("rust-atty" ,rust-atty-0.2)
286 ("rust-clap" ,rust-clap-2)
287 ("rust-ctrlc" ,rust-ctrlc-3)
288 ("rust-dirs" ,rust-dirs-2)
289 ("rust-globset" ,rust-globset-0.4)
290 ("rust-humantime" ,rust-humantime-2)
291 ("rust-ignore" ,rust-ignore-0.4)
292 ("rust-jemallocator" ,rust-jemallocator-0.3)
293 ("rust-lazy-static" ,rust-lazy-static-1)
294 ("rust-libc" ,rust-libc-0.2)
295 ("rust-lscolors" ,rust-lscolors-0.7)
296 ("rust-num-cpus" ,rust-num-cpus-1)
297 ("rust-regex" ,rust-regex-1)
298 ("rust-regex-syntax" ,rust-regex-syntax-0.6)
299 ("rust-users" ,rust-users-0.10)
300 ("rust-version-check" ,rust-version-check-0.9))
301 #:cargo-development-inputs
302 (("rust-diff" ,rust-diff-0.1)
303 ("rust-filetime" ,rust-filetime-0.2)
304 ("rust-tempdir" ,rust-tempdir-0.3))
305 #:phases
306 (modify-phases %standard-phases
307 (add-after 'unpack 'override-jemalloc
308 (lambda* (#:key inputs #:allow-other-keys)
309 (let ((jemalloc (assoc-ref inputs "jemalloc")))
310 (setenv "JEMALLOC_OVERRIDE"
311 (string-append jemalloc "/lib/libjemalloc.so")))
312 #t))
313 (add-after 'install 'install-extra
314 (lambda* (#:key outputs #:allow-other-keys)
315 (let* ((out (assoc-ref outputs "out"))
316 (install-completion
317 (lambda (completion out-dir)
318 (for-each
319 (lambda (f)
320 (install-file f (string-append out out-dir)))
321 (find-files "target/release/build/" completion)))))
322 ;; Manpages
323 (install-file "doc/fd.1" (string-append out "/share/man/man1"))
324 ;; Completions
325 (install-completion "^fd.bash$" "/etc/bash_completion.d")
326 (install-completion "^fd.fish$" "/share/fish/vendor_completions.d")
327 (install-completion "^_fd$" "/share/zsh/site-functions")
328 (rename-file (string-append out "/etc/bash_completion.d/fd.bash")
329 (string-append out "/etc/bash_completion.d/fd"))
330 #t))))))
331 (inputs `(("jemalloc" ,jemalloc)))
332 (home-page "https://github.com/sharkdp/fd")
333 (synopsis "Simple, fast and user-friendly alternative to find")
334 (description
335 "@code{fd} is a simple, fast and user-friendly alternative to @code{find}.
336 While it does not seek to mirror all of find's powerful functionality, it
337 provides defaults for 80% of the use cases.")
338 (license (list license:expat license:asl2.0))))
339
340 (define-public hexyl
341 (package
342 (name "hexyl")
343 (version "0.8.0")
344 (source
345 (origin
346 (method url-fetch)
347 (uri (crate-uri "hexyl" version))
348 (file-name
349 (string-append name "-" version ".tar.gz"))
350 (sha256
351 (base32
352 "0sipag77196467idbznbk5q5lwhqz85zw7y1pwg9b27jxqyk04rp"))))
353 (build-system cargo-build-system)
354 (arguments
355 `(#:cargo-inputs
356 (("rust-ansi-term" ,rust-ansi-term-0.12)
357 ("rust-atty" ,rust-atty-0.2)
358 ("rust-clap" ,rust-clap-2)
359 ("rust-libc" ,rust-libc-0.2))))
360 (home-page "https://github.com/sharkdp/hexyl")
361 (synopsis "Command-line hex viewer")
362 (description
363 "This package provides a command line hex viewer. It uses a colored output
364 for distinguishing different kinds of bytes such as NULL bytes, printable ASCII
365 characters, ASCII whitespace characters, other ASCII characters and non-ASCII.")
366 (license (list license:expat license:asl2.0))))
367
368 (define-public ripgrep
369 (package
370 (name "ripgrep")
371 (version "12.1.1")
372 (source
373 (origin
374 (method url-fetch)
375 (uri (crate-uri "ripgrep" version))
376 (file-name
377 (string-append name "-" version ".tar.gz"))
378 (sha256
379 (base32
380 "1grfi0j9zczzipipc21lkdbqmd2lvy2wlqy65fy4sckqvix5amdr"))))
381 (build-system cargo-build-system)
382 (arguments
383 `(#:cargo-inputs
384 (("rust-bstr" ,rust-bstr-0.2)
385 ("rust-clap" ,rust-clap-2)
386 ("rust-grep" ,rust-grep-0.2)
387 ("rust-ignore" ,rust-ignore-0.4)
388 ("rust-jemallocator" ,rust-jemallocator-0.3)
389 ("rust-lazy-static" ,rust-lazy-static-1)
390 ("rust-log" ,rust-log-0.4)
391 ("rust-num-cpus" ,rust-num-cpus-1)
392 ("rust-regex" ,rust-regex-1)
393 ("rust-serde-json" ,rust-serde-json-1)
394 ("rust-termcolor" ,rust-termcolor-1))
395 #:cargo-development-inputs
396 (("rust-serde" ,rust-serde-1)
397 ("rust-serde-derive" ,rust-serde-derive-1))
398 #:modules ((ice-9 match)
399 (guix build cargo-build-system)
400 (guix build utils))
401 #:phases
402 (modify-phases %standard-phases
403 (add-after 'build 'install-manpage
404 ;; NOTE: This is done before 'check so that there's only one output
405 ;; directory with the man page.
406 (lambda* (#:key outputs #:allow-other-keys)
407 (match (find-files "target" "^rg\\.1$")
408 ((manpage)
409 (install-file manpage (string-append
410 (assoc-ref outputs "out")
411 "/share/man/man1"))))
412 #t)))
413 #:features '("pcre2")))
414 (native-inputs
415 `(("asciidoc" ,asciidoc)
416 ("pcre2" ,pcre2)
417 ("pkg-config" ,pkg-config)))
418 (home-page "https://github.com/BurntSushi/ripgrep")
419 (synopsis "Line-oriented search tool")
420 (description
421 "ripgrep is a line-oriented search tool that recursively searches
422 your current directory for a regex pattern while respecting your
423 gitignore rules.")
424 (license (list license:unlicense license:expat))))
425
426 (define-public rust-cbindgen
427 (package
428 (name "rust-cbindgen")
429 (version "0.13.2")
430 (source
431 (origin
432 (method url-fetch)
433 (uri (crate-uri "cbindgen" version))
434 (file-name (string-append name "-" version ".crate"))
435 (sha256
436 (base32
437 "0673pq96hs7waavkv58v2pakpxpsfyjvbraa5kyl2b44phgdzcid"))))
438 (build-system cargo-build-system)
439 (arguments
440 `(#:cargo-inputs
441 (("clap" ,rust-clap-2)
442 ("log" ,rust-log-0.4)
443 ("proc-macro2" ,rust-proc-macro2-1)
444 ("quote" ,rust-quote-1)
445 ("serde" ,rust-serde-1)
446 ("serde-json" ,rust-serde-json-1)
447 ("syn" ,rust-syn-1)
448 ("tempfile" ,rust-tempfile-3)
449 ("toml" ,rust-toml-0.5))))
450 (home-page "https://github.com/eqrion/cbindgen/")
451 (synopsis "Tool for generating C bindings to Rust code")
452 (description
453 "This package provides a tool for generating C/C++ bindings to Rust code.")
454 (license license:mpl2.0)))
455
456 (define-public rust-cbindgen-0.16
457 (package
458 (inherit rust-cbindgen)
459 (name "rust-cbindgen")
460 (version "0.16.0")
461 (source
462 (origin
463 (method url-fetch)
464 (uri (crate-uri "cbindgen" version))
465 (file-name (string-append name "-" version ".tar.gz"))
466 (sha256
467 (base32 "049cai626nzw0km03parx4sxwaxgbr7i5ifjbjwnfxkqkj5k2i4k"))))
468 (arguments
469 `(#:tests? #false ;missing files
470 #:cargo-inputs
471 (("rust-clap" ,rust-clap-2)
472 ("rust-heck" ,rust-heck-0.3)
473 ("rust-indexmap" ,rust-indexmap-1)
474 ("rust-log" ,rust-log-0.4)
475 ("rust-proc-macro2" ,rust-proc-macro2-1)
476 ("rust-quote" ,rust-quote-1)
477 ("rust-serde" ,rust-serde-1)
478 ("rust-serde-json" ,rust-serde-json-1)
479 ("rust-syn" ,rust-syn-1)
480 ("rust-tempfile" ,rust-tempfile-3)
481 ("rust-toml" ,rust-toml-0.5))
482 #:cargo-development-inputs
483 (("rust-serial-test" ,rust-serial-test-0.5))))))
484
485 (define-public rust-cbindgen-0.15
486 (package
487 (inherit rust-cbindgen)
488 (name "rust-cbindgen")
489 (version "0.15.0")
490 (source
491 (origin
492 (method url-fetch)
493 (uri (crate-uri "cbindgen" version))
494 (file-name (string-append name "-" version ".tar.gz"))
495 (sha256
496 (base32 "0dgf49zij9rxnf0lv4k5gcmx1mxcz16czkk6q63anz0xp8ds3xhx"))))
497 (arguments
498 `(#:tests? #false ;missing files
499 #:cargo-inputs
500 (("rust-clap" ,rust-clap-2)
501 ("rust-heck" ,rust-heck-0.3)
502 ("rust-indexmap" ,rust-indexmap-1)
503 ("rust-log" ,rust-log-0.4)
504 ("rust-proc-macro2" ,rust-proc-macro2-1)
505 ("rust-quote" ,rust-quote-1)
506 ("rust-serde" ,rust-serde-1)
507 ("rust-serde-json" ,rust-serde-json-1)
508 ("rust-syn" ,rust-syn-1)
509 ("rust-tempfile" ,rust-tempfile-3)
510 ("rust-toml" ,rust-toml-0.5))))))
511
512 (define-public rust-cbindgen-0.14
513 (package
514 (inherit rust-cbindgen)
515 (name "rust-cbindgen")
516 (version "0.14.1")
517 (source
518 (origin
519 (method url-fetch)
520 (uri (crate-uri "cbindgen" version))
521 (file-name
522 (string-append name "-" version ".tar.gz"))
523 (sha256
524 (base32
525 "1ppwqbzydxlg9a24lynzfk60xrvqw4k31mpz1wrk6lbf88zf8nxi"))))))
526
527 (define-public rust-cbindgen-0.12
528 (package
529 (inherit rust-cbindgen)
530 (name "rust-cbindgen")
531 (version "0.12.2")
532 (source
533 (origin
534 (method url-fetch)
535 (uri (crate-uri "cbindgen" version))
536 (file-name
537 (string-append name "-" version ".tar.gz"))
538 (sha256
539 (base32
540 "13jzbmjz1bmmfr0i80hw6ar484mgabx3hbpb2ynhk0ddqi0yr58m"))))))
541
542 (define-public tectonic
543 (package
544 (name "tectonic")
545 (version "0.4.1")
546 (source
547 (origin
548 (method url-fetch)
549 (uri (crate-uri "tectonic" version))
550 (file-name (string-append name "-" version ".tar.gz"))
551 (sha256
552 (base32 "16fm2bfvfizrydmirzf0bhr1fidb5slcbvr6150and8yqr8jc4lf"))))
553 (build-system cargo-build-system)
554 (arguments
555 `(#:cargo-inputs
556 (("rust-app-dirs2" ,rust-app-dirs2-2)
557 ("rust-atty" ,rust-atty-0.2)
558 ("rust-byte-unit" ,rust-byte-unit-4)
559 ("rust-cbindgen" ,rust-cbindgen-0.16)
560 ("rust-cc" ,rust-cc-1)
561 ("rust-cfg-if" ,rust-cfg-if-1)
562 ("rust-error-chain" ,rust-error-chain-0.12)
563 ("rust-flate2" ,rust-flate2-1)
564 ("rust-fs2" ,rust-fs2-0.4)
565 ("rust-headers" ,rust-headers-0.2)
566 ("rust-lazy-static" ,rust-lazy-static-1)
567 ("rust-libc" ,rust-libc-0.2)
568 ("rust-md-5" ,rust-md-5-0.9)
569 ("rust-pkg-config" ,rust-pkg-config-0.3)
570 ("rust-regex" ,rust-regex-1)
571 ("rust-reqwest" ,rust-reqwest-0.9)
572 ("rust-serde" ,rust-serde-1)
573 ("rust-sha2" ,rust-sha2-0.9)
574 ("rust-structopt" ,rust-structopt-0.3)
575 ("rust-tectonic-cfg-support" ,rust-tectonic-cfg-support-0.1)
576 ("rust-tectonic-xdv" ,rust-tectonic-xdv-0.1)
577 ("rust-tempfile" ,rust-tempfile-3)
578 ("rust-termcolor" ,rust-termcolor-1)
579 ("rust-toml" ,rust-toml-0.5)
580 ("rust-vcpkg" ,rust-vcpkg-0.2)
581 ("rust-zip" ,rust-zip-0.5))
582 #:cargo-development-inputs
583 (("rust-filetime" ,rust-filetime-0.2)
584 ("rust-futures" ,rust-futures-0.1)
585 ("rust-headers" ,rust-headers-0.2)
586 ("rust-hyper" ,rust-hyper-0.12)
587 ("rust-tempfile" ,rust-tempfile-3)
588 ("rust-tokio" ,rust-tokio-0.1))
589 #:phases
590 (modify-phases %standard-phases
591 (add-after 'install 'install-doc
592 (lambda* (#:key outputs #:allow-other-keys)
593 (let* ((out (assoc-ref outputs "out"))
594 (doc (string-append out "/share/doc/" ,name "-" ,version)))
595 (copy-recursively "docs/src" doc)
596 #t))))))
597 (native-inputs
598 `(("pkg-config" ,pkg-config)))
599 (inputs
600 `(("fontconfig" ,fontconfig)
601 ("harfbuzz" ,harfbuzz)
602 ("openssl" ,openssl)
603 ("zlib" ,zlib)))
604 (home-page "https://tectonic-typesetting.github.io/")
605 (synopsis "Complete, embeddable TeX/LaTeX engine")
606 (description
607 "This package provides a modernized, complete, embeddable
608 TeX/LaTeX engine. Tectonic is forked from the XeTeX extension to the
609 classic Web2C implementation of TeX and uses the TeXLive distribution
610 of support files.")
611 (license license:expat)))
612
613 (define-public tokei
614 (package
615 (name "tokei")
616 (version "12.1.2")
617 (source
618 (origin
619 (method url-fetch)
620 (uri (crate-uri "tokei" version))
621 (file-name (string-append name "-" version ".tar.gz"))
622 (sha256
623 (base32 "000w549v1bpw7r57xw656p40ywf1gimvxxx5cjnri2js0xg927x4"))))
624 (build-system cargo-build-system)
625 (arguments
626 `(#:cargo-inputs
627 (("rust-aho-corasick" ,rust-aho-corasick-0.7)
628 ("rust-clap" ,rust-clap-2)
629 ("rust-crossbeam-channel" ,rust-crossbeam-channel-0.5)
630 ("rust-dashmap" ,rust-dashmap-4)
631 ("rust-dirs" ,rust-dirs-3)
632 ("rust-encoding-rs-io" ,rust-encoding-rs-io-0.1)
633 ("rust-env-logger" ,rust-env-logger-0.8)
634 ("rust-grep-searcher" ,rust-grep-searcher-0.1)
635 ("rust-hex" ,rust-hex-0.4)
636 ("rust-ignore" ,rust-ignore-0.4)
637 ("rust-log" ,rust-log-0.4)
638 ("rust-num-format" ,rust-num-format-0.4)
639 ("rust-once-cell" ,rust-once-cell-1)
640 ("rust-parking-lot" ,rust-parking-lot-0.11)
641 ("rust-rayon" ,rust-rayon-1)
642 ("rust-regex" ,rust-regex-1)
643 ("rust-serde" ,rust-serde-1)
644 ("rust-serde-cbor" ,rust-serde-cbor-0.11)
645 ("rust-serde-json" ,rust-serde-json-1)
646 ("rust-serde-yaml" ,rust-serde-yaml-0.8)
647 ("rust-tera" ,rust-tera-1)
648 ("rust-term-size" ,rust-term-size-0.3)
649 ("rust-toml" ,rust-toml-0.5))
650 #:cargo-development-inputs
651 (("rust-git2" ,rust-git2-0.13)
652 ("rust-regex" ,rust-regex-1)
653 ("rust-tempfile" ,rust-tempfile-3))))
654 (native-inputs
655 `(("pkg-config" ,pkg-config)))
656 (inputs
657 `(("libgit2" ,libgit2)
658 ("openssl" ,openssl)
659 ("zlib" ,zlib)))
660 (home-page "https://tokei.rs")
661 (synopsis "Count code, quickly")
662 (description
663 "Tokei is a program that displays statistics about your code. Tokei will
664 show number of files, total lines within those files and code, comments, and
665 blanks grouped by language.")
666 (license (list license:expat license:asl2.0))))
667
668 (define-public watchexec
669 (package
670 (name "watchexec")
671 (version "1.14.1")
672 (source
673 (origin
674 (method url-fetch)
675 (uri (crate-uri "watchexec" version))
676 (file-name
677 (string-append name "-" version ".tar.gz"))
678 (sha256
679 (base32 "1vqaa462sjpzi0crh12ixqc2wa5bblirc129pnj8jr8iz3xw3gvd"))))
680 (build-system cargo-build-system)
681 (arguments
682 `(#:phases
683 (modify-phases %standard-phases
684 (add-after 'install 'install-completions
685 (lambda* (#:key outputs #:allow-other-keys)
686 (let* ((out (assoc-ref outputs "out"))
687 (zsh (string-append out "/share/zsh/site-functions/_watchexec"))
688 (doc (string-append out "/share/doc/watchexec-" ,version)))
689 (mkdir-p (dirname zsh))
690 (copy-file "completions/zsh" zsh)
691 (install-file "README.md" doc)
692 #t))))
693 #:cargo-inputs
694 (("rust-embed-resource" ,rust-embed-resource-1)
695 ("rust-derive-builder" ,rust-derive-builder-0.9)
696 ("rust-env-logger" ,rust-env-logger-0.7)
697 ("rust-glob" ,rust-glob-0.3)
698 ("rust-globset" ,rust-globset-0.4)
699 ("rust-lazy-static" ,rust-lazy-static-1)
700 ("rust-log" ,rust-log-0.4)
701 ("rust-nix" ,rust-nix-0.17)
702 ("rust-notify" ,rust-notify-4)
703 ("rust-walkdir" ,rust-walkdir-2))))
704 (home-page "https://github.com/watchexec/watchexec")
705 (synopsis "Executes commands in response to file modifications")
706 (description
707 "@command{watchexec} is a simple, standalone tool that watches a path and runs
708 a command whenever it detects modifications.
709
710 Example use cases:
711 @itemize @bullet
712 @item Automatically run unit tests
713 @item Run linters/syntax checkers
714 @end itemize
715
716 Features:
717 @itemize @bullet
718 @item Coalesces multiple file system events into one, for editors that
719 use swap/backup files during saving
720 @item By default, uses @code{.gitignore} and @code{.ignore} to determine which
721 files to ignore notifications for
722 @item Supports watching files with a specific extension
723 @item Supports filtering/ignoring events based on glob patterns
724 @item Launches child processes in a new process group
725 @item Sets environment variables that allow the executed program to learn
726 the details of how it was triggered.
727 @end itemize")
728 (license license:asl2.0)))
729
730 (define-public rust-cargo-c
731 (package
732 (name "rust-cargo-c")
733 (version "0.5.3")
734 (source
735 (origin
736 (method url-fetch)
737 (uri (crate-uri "cargo-c" version))
738 (file-name
739 (string-append name "-" version ".tar.gz"))
740 (sha256
741 (base32
742 "0hsag5g4qngm8alfil2dyvl5sagpqi5nb40c7bhwng2z8mv9r41k"))))
743 (build-system cargo-build-system)
744 (arguments
745 `(#:cargo-inputs
746 (("rust-cbindgen" ,rust-cbindgen)
747 ("rust-pretty-env-logger" ,rust-pretty-env-logger-0.4)
748 ("rust-structopt" ,rust-structopt-0.3)
749 ("rust-log" ,rust-log-0.4)
750 ("rust-toml" ,rust-toml-0.5)
751 ("rust-cargo-metadata" ,rust-cargo-metadata-0.9)
752 ("rust-serde" ,rust-serde-1)
753 ("rust-serde-derive" ,rust-serde-derive-1)
754 ("rust-regex" ,rust-regex-1))))
755 (home-page "https://github.com/lu-zero/cargo-c")
756 (synopsis "Build and install C-compatible libraries")
757 (description
758 "This package produces and installs a correct pkg-config file, a static
759 library and a dynamic library, and a C header to be used by any C (and
760 C-compatible) software.")
761 (license license:expat)))