on master help sign in
Remove 'liquid' dependency
commitf18009e5d57bb4ee03511a9a2b6fd933d58d539f authorsharkdp <davidpeter@web.de> dateSun 20 Sep 2020, 19:50 (6 years ago) parent83c7750
5 files changed+24−290
CHANGELOG.md+3−1 Cargo.lock−272 Cargo.toml+3−5 assets/manual/bat.1.in+1−1 build.rs+17−11
CHANGELOG.md+3−1
@@ -1,5 +1,4 @@
11# unreleased
2−- Handle file extension conflicts in --list-languages, see #1076 and #1135 (@Kienyew)
32
43
54## Features
@@ -11,6 +10,7 @@
1110## Bugfixes
1211
1312- Fixed non-printable characters display for redirected output, see #1061 (@gsomix)
13+- Handle file extension conflicts in --list-languages, see #1076 and #1135 (@Kienyew)
1414
1515## Other
1616- Switched to "·" (U+00B7) Middle Dot from "•" (U+2022) Bullet for non-printing spaces, see #1056 and #1100 (@LordFlashmeow)
@@ -35,6 +35,8 @@
3535
3636## Packaging
3737
38+- Removed build dependency on `liquid` (@sharkdp).
39+
3840# v0.15.4
3941
4042## Bugfixes
Cargo.lock−272
@@ -37,11 +37,6 @@ dependencies = [
3737 "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
3838]
3939
40−[[package]]
41−name = "anymap"
42−version = "0.12.1"
43−source = "registry+https://github.com/rust-lang/crates.io-index"
44−
4540[[package]]
4641name = "arrayref"
4742version = "0.3.6"
@@ -106,7 +101,6 @@ dependencies = [
106101 "git2 0.13.8 (registry+https://github.com/rust-lang/crates.io-index)",
107102 "globset 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)",
108103 "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
109− "liquid 0.21.4 (registry+https://github.com/rust-lang/crates.io-index)",
110104 "path_abs 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
111105 "predicates 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)",
112106 "semver 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -156,25 +150,6 @@ dependencies = [
156150 "constant_time_eq 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
157151]
158152
159−[[package]]
160−name = "block-buffer"
161−version = "0.7.3"
162−source = "registry+https://github.com/rust-lang/crates.io-index"
163−dependencies = [
164− "block-padding 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
165− "byte-tools 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
166− "byteorder 1.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
167− "generic-array 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)",
168−]
169−
170−[[package]]
171−name = "block-padding"
172−version = "0.1.5"
173−source = "registry+https://github.com/rust-lang/crates.io-index"
174−dependencies = [
175− "byte-tools 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
176−]
177−
178153[[package]]
179154name = "bstr"
180155version = "0.2.12"
@@ -183,11 +158,6 @@ dependencies = [
183158 "memchr 2.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
184159]
185160
186−[[package]]
187−name = "byte-tools"
188−version = "0.3.1"
189−source = "registry+https://github.com/rust-lang/crates.io-index"
190−
191161[[package]]
192162name = "byteorder"
193163version = "1.3.4"
@@ -213,7 +183,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
213183dependencies = [
214184 "num-integer 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)",
215185 "num-traits 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
216− "time 0.1.43 (registry+https://github.com/rust-lang/crates.io-index)",
217186]
218187
219188[[package]]
@@ -283,14 +252,6 @@ name = "difference"
283252version = "2.0.0"
284253source = "registry+https://github.com/rust-lang/crates.io-index"
285254
286−[[package]]
287−name = "digest"
288−version = "0.8.1"
289−source = "registry+https://github.com/rust-lang/crates.io-index"
290−dependencies = [
291− "generic-array 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)",
292−]
293−
294255[[package]]
295256name = "dirs"
296257version = "3.0.1"
@@ -319,11 +280,6 @@ name = "dtoa"
319280version = "0.4.5"
320281source = "registry+https://github.com/rust-lang/crates.io-index"
321282
322−[[package]]
323−name = "either"
324−version = "1.5.3"
325−source = "registry+https://github.com/rust-lang/crates.io-index"
326−
327283[[package]]
328284name = "encode_unicode"
329285version = "0.3.6"
@@ -394,11 +350,6 @@ dependencies = [
394350 "version_check 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
395351]
396352
397−[[package]]
398−name = "fake-simd"
399−version = "0.1.2"
400−source = "registry+https://github.com/rust-lang/crates.io-index"
401−
402353[[package]]
403354name = "fancy-regex"
404355version = "0.3.3"
@@ -437,14 +388,6 @@ name = "fuchsia-cprng"
437388version = "0.1.1"
438389source = "registry+https://github.com/rust-lang/crates.io-index"
439390
440−[[package]]
441−name = "generic-array"
442−version = "0.12.3"
443−source = "registry+https://github.com/rust-lang/crates.io-index"
444−dependencies = [
445− "typenum 1.12.0 (registry+https://github.com/rust-lang/crates.io-index)",
446−]
447−
448391[[package]]
449392name = "getrandom"
450393version = "0.1.14"
@@ -510,14 +453,6 @@ dependencies = [
510453 "autocfg 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
511454]
512455
513−[[package]]
514−name = "itertools"
515−version = "0.9.0"
516−source = "registry+https://github.com/rust-lang/crates.io-index"
517−dependencies = [
518− "either 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)",
519−]
520−
521456[[package]]
522457name = "itoa"
523458version = "0.4.5"
@@ -540,14 +475,6 @@ dependencies = [
540475 "winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
541476]
542477
543−[[package]]
544−name = "kstring"
545−version = "1.0.0"
546−source = "registry+https://github.com/rust-lang/crates.io-index"
547−dependencies = [
548− "serde 1.0.114 (registry+https://github.com/rust-lang/crates.io-index)",
549−]
550−
551478[[package]]
552479name = "lazy_static"
553480version = "1.4.0"
@@ -598,60 +525,6 @@ name = "linked-hash-map"
598525version = "0.5.2"
599526source = "registry+https://github.com/rust-lang/crates.io-index"
600527
601−[[package]]
602−name = "liquid"
603−version = "0.21.4"
604−source = "registry+https://github.com/rust-lang/crates.io-index"
605−dependencies = [
606− "doc-comment 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
607− "kstring 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
608− "liquid-core 0.21.0 (registry+https://github.com/rust-lang/crates.io-index)",
609− "liquid-derive 0.21.0 (registry+https://github.com/rust-lang/crates.io-index)",
610− "liquid-lib 0.21.1 (registry+https://github.com/rust-lang/crates.io-index)",
611− "serde 1.0.114 (registry+https://github.com/rust-lang/crates.io-index)",
612−]
613−
614−[[package]]
615−name = "liquid-core"
616−version = "0.21.0"
617−source = "registry+https://github.com/rust-lang/crates.io-index"
618−dependencies = [
619− "anymap 0.12.1 (registry+https://github.com/rust-lang/crates.io-index)",
620− "chrono 0.4.11 (registry+https://github.com/rust-lang/crates.io-index)",
621− "itertools 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
622− "kstring 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
623− "liquid-derive 0.21.0 (registry+https://github.com/rust-lang/crates.io-index)",
624− "num-traits 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
625− "pest 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
626− "pest_derive 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
627− "serde 1.0.114 (registry+https://github.com/rust-lang/crates.io-index)",
628−]
629−
630−[[package]]
631−name = "liquid-derive"
632−version = "0.21.0"
633−source = "registry+https://github.com/rust-lang/crates.io-index"
634−dependencies = [
635− "proc-macro2 1.0.18 (registry+https://github.com/rust-lang/crates.io-index)",
636− "proc-quote 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
637− "syn 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
638−]
639−
640−[[package]]
641−name = "liquid-lib"
642−version = "0.21.1"
643−source = "registry+https://github.com/rust-lang/crates.io-index"
644−dependencies = [
645− "chrono 0.4.11 (registry+https://github.com/rust-lang/crates.io-index)",
646− "itertools 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
647− "kstring 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
648− "liquid-core 0.21.0 (registry+https://github.com/rust-lang/crates.io-index)",
649− "once_cell 1.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
650− "percent-encoding 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
651− "regex 1.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
652− "unicode-segmentation 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
653−]
654−
655528[[package]]
656529name = "log"
657530version = "0.4.8"
@@ -660,11 +533,6 @@ dependencies = [
660533 "cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)",
661534]
662535
663−[[package]]
664−name = "maplit"
665−version = "1.0.2"
666−source = "registry+https://github.com/rust-lang/crates.io-index"
667−
668536[[package]]
669537name = "matches"
670538version = "0.1.8"
@@ -705,11 +573,6 @@ dependencies = [
705573 "autocfg 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
706574]
707575
708−[[package]]
709−name = "once_cell"
710−version = "1.3.1"
711−source = "registry+https://github.com/rust-lang/crates.io-index"
712−
713576[[package]]
714577name = "onig"
715578version = "6.0.0"
@@ -730,11 +593,6 @@ dependencies = [
730593 "pkg-config 0.3.17 (registry+https://github.com/rust-lang/crates.io-index)",
731594]
732595
733−[[package]]
734−name = "opaque-debug"
735−version = "0.2.3"
736−source = "registry+https://github.com/rust-lang/crates.io-index"
737−
738596[[package]]
739597name = "path_abs"
740598version = "0.5.0"
@@ -748,45 +606,6 @@ name = "percent-encoding"
748606version = "2.1.0"
749607source = "registry+https://github.com/rust-lang/crates.io-index"
750608
751−[[package]]
752−name = "pest"
753−version = "2.1.3"
754−source = "registry+https://github.com/rust-lang/crates.io-index"
755−dependencies = [
756− "ucd-trie 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
757−]
758−
759−[[package]]
760−name = "pest_derive"
761−version = "2.1.0"
762−source = "registry+https://github.com/rust-lang/crates.io-index"
763−dependencies = [
764− "pest 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
765− "pest_generator 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
766−]
767−
768−[[package]]
769−name = "pest_generator"
770−version = "2.1.3"
771−source = "registry+https://github.com/rust-lang/crates.io-index"
772−dependencies = [
773− "pest 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
774− "pest_meta 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
775− "proc-macro2 1.0.18 (registry+https://github.com/rust-lang/crates.io-index)",
776− "quote 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)",
777− "syn 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
778−]
779−
780−[[package]]
781−name = "pest_meta"
782−version = "2.1.3"
783−source = "registry+https://github.com/rust-lang/crates.io-index"
784−dependencies = [
785− "maplit 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
786− "pest 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
787− "sha-1 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)",
788−]
789−
790609[[package]]
791610name = "pkg-config"
792611version = "0.3.17"
@@ -831,11 +650,6 @@ dependencies = [
831650 "treeline 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
832651]
833652
834−[[package]]
835−name = "proc-macro-hack"
836−version = "0.5.15"
837−source = "registry+https://github.com/rust-lang/crates.io-index"
838−
839653[[package]]
840654name = "proc-macro2"
841655version = "1.0.18"
@@ -844,28 +658,6 @@ dependencies = [
844658 "unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
845659]
846660
847−[[package]]
848−name = "proc-quote"
849−version = "0.3.2"
850−source = "registry+https://github.com/rust-lang/crates.io-index"
851−dependencies = [
852− "proc-macro-hack 0.5.15 (registry+https://github.com/rust-lang/crates.io-index)",
853− "proc-macro2 1.0.18 (registry+https://github.com/rust-lang/crates.io-index)",
854− "proc-quote-impl 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
855− "quote 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)",
856− "syn 1.0.33 (registry+https://github.com/rust-lang/crates.io-index)",
857−]
858−
859−[[package]]
860−name = "proc-quote-impl"
861−version = "0.3.2"
862−source = "registry+https://github.com/rust-lang/crates.io-index"
863−dependencies = [
864− "proc-macro-hack 0.5.15 (registry+https://github.com/rust-lang/crates.io-index)",
865− "proc-macro2 1.0.18 (registry+https://github.com/rust-lang/crates.io-index)",
866− "quote 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)",
867−]
868−
869661[[package]]
870662name = "quote"
871663version = "1.0.3"
@@ -1027,17 +819,6 @@ dependencies = [
1027819 "yaml-rust 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
1028820]
1029821
1030−[[package]]
1031−name = "sha-1"
1032−version = "0.8.2"
1033−source = "registry+https://github.com/rust-lang/crates.io-index"
1034−dependencies = [
1035− "block-buffer 0.7.3 (registry+https://github.com/rust-lang/crates.io-index)",
1036− "digest 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
1037− "fake-simd 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
1038− "opaque-debug 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
1039−]
1040−
1041822[[package]]
1042823name = "shell-words"
1043824version = "1.0.0"
@@ -1143,30 +924,11 @@ dependencies = [
1143924 "lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
1144925]
1145926
1146−[[package]]
1147−name = "time"
1148−version = "0.1.43"
1149−source = "registry+https://github.com/rust-lang/crates.io-index"
1150−dependencies = [
1151− "libc 0.2.69 (registry+https://github.com/rust-lang/crates.io-index)",
1152− "winapi 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
1153−]
1154−
1155927[[package]]
1156928name = "treeline"
1157929version = "0.1.0"
1158930source = "registry+https://github.com/rust-lang/crates.io-index"
1159931
1160−[[package]]
1161−name = "typenum"
1162−version = "1.12.0"
1163−source = "registry+https://github.com/rust-lang/crates.io-index"
1164−
1165−[[package]]
1166−name = "ucd-trie"
1167−version = "0.1.3"
1168−source = "registry+https://github.com/rust-lang/crates.io-index"
1169−
1170932[[package]]
1171933name = "unicode-bidi"
1172934version = "0.3.4"
@@ -1183,11 +945,6 @@ dependencies = [
1183945 "smallvec 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
1184946]
1185947
1186−[[package]]
1187−name = "unicode-segmentation"
1188−version = "1.6.0"
1189−source = "registry+https://github.com/rust-lang/crates.io-index"
1190−
1191948[[package]]
1192949name = "unicode-width"
1193950version = "0.1.8"
@@ -1310,7 +1067,6 @@ dependencies = [
13101067"checksum ansi_colours 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "1d0f302a81afc6a7f4350c04f0ba7cfab529cc009bca3324b3fb5764e6add8b6"
13111068"checksum ansi_term 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ee49baf6cb617b853aa8d93bf420db2383fab46d314482ca2803b40d5fde979b"
13121069"checksum ansi_term 0.12.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d52a9bb7ec0cf484c551830a7ce27bd20d67eac647e1befb56b0be4ee39a55d2"
1313−"checksum anymap 0.12.1 (registry+https://github.com/rust-lang/crates.io-index)" = "33954243bd79057c2de7338850b85983a44588021f8a5fee574a8888c6de4344"
13141070"checksum arrayref 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "a4c527152e37cf757a3f78aae5a06fbeefdb07ccc535c980a3208ee3060dd544"
13151071"checksum arrayvec 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "cff77d8686867eceff3105329d4698d96c2391c176d5d03adc90c7389162b5b8"
13161072"checksum assert_cmd 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c88b9ca26f9c16ec830350d309397e74ee9abdfd8eb1f71cb6ecc71a3fc818da"
@@ -1323,10 +1079,7 @@ dependencies = [
13231079"checksum bit-vec 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "f59bbe95d4e52a6398ec21238d31577f2b28a9d86807f06ca59d191d8440d0bb"
13241080"checksum bitflags 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "cf1de2fe8c75bc145a2f577add951f8134889b4795d47466a54a5c846d691693"
13251081"checksum blake2b_simd 0.5.10 (registry+https://github.com/rust-lang/crates.io-index)" = "d8fb2d74254a3a0b5cac33ac9f8ed0e44aa50378d9dbb2e5d83bd21ed1dc2c8a"
1326−"checksum block-buffer 0.7.3 (registry+https://github.com/rust-lang/crates.io-index)" = "c0940dc441f31689269e10ac70eb1002a3a1d3ad1390e030043662eb7fe4688b"
1327−"checksum block-padding 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "fa79dedbb091f449f1f39e53edf88d5dbe95f895dae6135a8d7b881fb5af73f5"
13281082"checksum bstr 0.2.12 (registry+https://github.com/rust-lang/crates.io-index)" = "2889e6d50f394968c8bf4240dc3f2a7eb4680844d27308f798229ac9d4725f41"
1329−"checksum byte-tools 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "e3b5ca7a04898ad4bcd41c90c5285445ff5b791899bb1b0abdd2a2aa791211d7"
13301083"checksum byteorder 1.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "08c48aae112d48ed9f069b33538ea9e3e90aa263cfa3d1c24309612b1f7472de"
13311084"checksum cc 1.0.52 (registry+https://github.com/rust-lang/crates.io-index)" = "c3d87b23d6a92cd03af510a5ade527033f6aa6fa92161e2d5863a907d4c5e31d"
13321085"checksum cfg-if 0.1.10 (registry+https://github.com/rust-lang/crates.io-index)" = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822"
@@ -1338,12 +1091,10 @@ dependencies = [
13381091"checksum crc32fast 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ba125de2af0df55319f41944744ad91c71113bf74a4646efff39afe1f6842db1"
13391092"checksum crossbeam-utils 0.7.2 (registry+https://github.com/rust-lang/crates.io-index)" = "c3c7c73a2d1e9fc0886a08b93e98eb643461230d5f1925e4036204d5f2e261a8"
13401093"checksum difference 2.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "524cbf6897b527295dff137cec09ecf3a05f4fddffd7dfcd1585403449e74198"
1341−"checksum digest 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)" = "f3d0c8c8752312f9713efd397ff63acb9f85585afbf179282e720e7704954dd5"
13421094"checksum dirs 3.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "142995ed02755914747cc6ca76fc7e4583cd18578746716d0508ea6ed558b9ff"
13431095"checksum dirs-sys 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)" = "8e93d7f5705de3e49895a2b5e0b8855a1c27f080192ae9c32a6432d50741a57a"
13441096"checksum doc-comment 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "fea41bba32d969b513997752735605054bc0dfa92b4c56bf1189f2e174be7a10"
13451097"checksum dtoa 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)" = "4358a9e11b9a09cf52383b451b49a169e8d797b68aa02301ff586d70d9661ea3"
1346−"checksum either 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)" = "bb1f6b1ce1c140482ea30ddd3335fc0024ac7ee112895426e0a629a6c20adfe3"
13471098"checksum encode_unicode 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "a357d28ed41a50f9c765dbfe56cbc04a64e53e5fc58ba79fbc34c10ef3df831f"
13481099"checksum encoding 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)" = "6b0d943856b990d12d3b55b359144ff341533e516d94098b1d3fc1ac666d36ec"
13491100"checksum encoding-index-japanese 1.20141219.5 (registry+https://github.com/rust-lang/crates.io-index)" = "04e8b2ff42e9a05335dbf8b5c6f7567e5591d0d916ccef4e0b1710d32a0d0c91"
@@ -1353,13 +1104,11 @@ dependencies = [
13531104"checksum encoding-index-tradchinese 1.20141219.5 (registry+https://github.com/rust-lang/crates.io-index)" = "fd0e20d5688ce3cab59eb3ef3a2083a5c77bf496cb798dc6fcdb75f323890c18"
13541105"checksum encoding_index_tests 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "a246d82be1c9d791c5dfde9a2bd045fc3cbba3fa2b11ad558f27d01712f00569"
13551106"checksum error-chain 0.12.4 (registry+https://github.com/rust-lang/crates.io-index)" = "2d2f06b9cac1506ece98fe3231e3cc9c4410ec3d5b1f24ae1c8946f0742cdefc"
1356−"checksum fake-simd 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "e88a8acf291dafb59c2d96e8f59828f3838bb1a70398823ade51a84de6a6deed"
13571107"checksum fancy-regex 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "b0e2de1b89ad299d536b7cefc5d177f5c005957fa2266ce58eca4d189e74bff5"
13581108"checksum flate2 1.0.14 (registry+https://github.com/rust-lang/crates.io-index)" = "2cfff41391129e0a856d6d822600b8d71179d46879e310417eb9c762eb178b42"
13591109"checksum float-cmp 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e1267f4ac4f343772758f7b1bdcbe767c218bbab93bb432acbf5162bbf85a6c4"
13601110"checksum fnv 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)" = "2fad85553e09a6f881f739c29f0b00b0f01357c743266d478b68951ce23285f3"
13611111"checksum fuchsia-cprng 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "a06f77d526c1a601b7c4cdd98f54b5eaabffc14d5f2f0296febdc7f357c6d3ba"
1362−"checksum generic-array 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)" = "c68f0274ae0e023facc3c97b2e00f076be70e254bc851d972503b328db79b2ec"
13631112"checksum getrandom 0.1.14 (registry+https://github.com/rust-lang/crates.io-index)" = "7abc8dd8451921606d809ba32e95b6111925cd2906060d2dcc29c070220503eb"
13641113"checksum git2 0.13.8 (registry+https://github.com/rust-lang/crates.io-index)" = "e6ac22e49b7d886b6802c66662b12609452248b1bc9e87d6d83ecea3db96f557"
13651114"checksum glob 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "9b919933a397b79c37e33b77bb2aa3dc8eb6e165ad809e58ff75bc7db2e34574"
@@ -1367,11 +1116,9 @@ dependencies = [
13671116"checksum hermit-abi 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)" = "8a0d737e0f947a1864e93d33fdef4af8445a00d1ed8dc0c8ddb73139ea6abf15"
13681117"checksum idna 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "02e2673c30ee86b5b96a9cb52ad15718aa1f966f5ab9ad54a8b95d5ca33120a9"
13691118"checksum indexmap 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "076f042c5b7b98f31d205f1249267e12a6518c1481e9dae9764af19b707d2292"
1370−"checksum itertools 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "284f18f85651fe11e8a991b2adb42cb078325c996ed026d994719efcfca1d54b"
13711119"checksum itoa 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)" = "b8b7a7c0c47db5545ed3fef7468ee7bb5b74691498139e4b3f6a20685dc6dd8e"
13721120"checksum jobserver 0.1.21 (registry+https://github.com/rust-lang/crates.io-index)" = "5c71313ebb9439f74b00d9d2dcec36440beaf57a6aa0623068441dd7cd81a7f2"
13731121"checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d"
1374−"checksum kstring 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c57805476d785f188945321cb408a1f240b62240d1f930096c1abcf08a00b4b4"
13751122"checksum lazy_static 1.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646"
13761123"checksum lazycell 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b294d6fa9ee409a054354afc4352b0b9ef7ca222c69b8812cbea9e7d2bf3783f"
13771124"checksum libc 0.2.69 (registry+https://github.com/rust-lang/crates.io-index)" = "99e85c08494b21a9054e7fe1374a732aeadaff3980b6990b94bfd3a70f690005"
@@ -1379,37 +1126,23 @@ dependencies = [
13791126"checksum libz-sys 1.0.25 (registry+https://github.com/rust-lang/crates.io-index)" = "2eb5e43362e38e2bca2fd5f5134c4d4564a23a5c28e9b95411652021a8675ebe"
13801127"checksum line-wrap 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "f30344350a2a51da54c1d53be93fade8a237e545dbcc4bdbe635413f2117cab9"
13811128"checksum linked-hash-map 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "ae91b68aebc4ddb91978b11a1b02ddd8602a05ec19002801c5666000e05e0f83"
1382−"checksum liquid 0.21.4 (registry+https://github.com/rust-lang/crates.io-index)" = "9f3d2ea80af5c2da5b2984fd98613db331dc9ad098782847b090a6a2405e5592"
1383−"checksum liquid-core 0.21.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7fd064f01f0fe12440844474a08f3b977220bdb88c7f691cbb9ce611da3b1e29"
1384−"checksum liquid-derive 0.21.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c138e9b1b94270041bec237898fac64cec12b533675ddff67956a97be42aca2b"
1385−"checksum liquid-lib 0.21.1 (registry+https://github.com/rust-lang/crates.io-index)" = "aa430745b78473580485ced0b9ff2403877c9ba13f3eeceaffb679ac641929c5"
13861129"checksum log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)" = "14b6052be84e6b71ab17edffc2eeabf5c2c3ae1fdb464aae35ac50c67a44e1f7"
1387−"checksum maplit 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "3e2e65a1a2e43cfcb47a895c4c8b10d1f4a61097f9f254f183aee60cad9c651d"
13881130"checksum matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "7ffc5c5338469d4d3ea17d269fa8ea3512ad247247c30bd2df69e68309ed0a08"
13891131"checksum memchr 2.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "3728d817d99e5ac407411fa471ff9800a778d88a24685968b36824eaf4bee400"
13901132"checksum miniz_oxide 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "aa679ff6578b1cddee93d7e82e263b94a575e0bfced07284eb0c037c1d2416a5"
13911133"checksum normalize-line-endings 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "61807f77802ff30975e01f4f071c8ba10c022052f98b3294119f3e615d13e5be"
13921134"checksum num-integer 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)" = "3f6ea62e9d81a77cd3ee9a2a5b9b609447857f3d358704331e4ef39eb247fcba"
13931135"checksum num-traits 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "c62be47e61d1842b9170f0fdeec8eba98e60e90e5446449a0545e5152acd7096"
1394−"checksum once_cell 1.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "b1c601810575c99596d4afc46f78a678c80105117c379eb3650cf99b8a21ce5b"
13951136"checksum onig 6.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "bd91ccd8a02fce2f7e8a86655aec67bc6c171e6f8e704118a0e8c4b866a05a8a"
13961137"checksum onig_sys 69.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "3814583fad89f3c60ae0701d80e87e1fd3028741723deda72d0d4a0ecf0cb0db"
1397−"checksum opaque-debug 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "2839e79665f131bdb5782e51f2c6c9599c133c6098982a54c794358bf432529c"
13981138"checksum path_abs 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "eb6b8e6dede0bf94e9300e669f335ba92d5fc9fc8be7f4b1ca8a05206489388c"
13991139"checksum percent-encoding 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d4fd5641d01c8f18a23da7b6fe29298ff4b55afcccdf78973b24cf3175fee32e"
1400−"checksum pest 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "10f4872ae94d7b90ae48754df22fd42ad52ce740b8f370b03da4835417403e53"
1401−"checksum pest_derive 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "833d1ae558dc601e9a60366421196a8d94bc0ac980476d0b67e1d0988d72b2d0"
1402−"checksum pest_generator 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "99b8db626e31e5b81787b9783425769681b347011cc59471e33ea46d2ea0cf55"
1403−"checksum pest_meta 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "54be6e404f5317079812fc8f9f5279de376d8856929e21c184ecf6bbd692a11d"
14041140"checksum pkg-config 0.3.17 (registry+https://github.com/rust-lang/crates.io-index)" = "05da548ad6865900e60eaba7f589cc0783590a92e940c26953ff81ddbab2d677"
14051141"checksum plist 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7b336d94e8e4ce29bf15bba393164629764744c567e8ad306cc1fdd0119967fd"
14061142"checksum predicates 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)" = "96bfead12e90dccead362d62bb2c90a5f6fc4584963645bc7f71a735e0b0735a"
14071143"checksum predicates-core 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "06075c3a3e92559ff8929e7a280684489ea27fe44805174c3ebd9328dcb37178"
14081144"checksum predicates-tree 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8e63c4859013b38a76eca2414c64911fba30def9e3202ac461a2d22831220124"
1409−"checksum proc-macro-hack 0.5.15 (registry+https://github.com/rust-lang/crates.io-index)" = "0d659fe7c6d27f25e9d80a1a094c223f5246f6a6596453e09d7229bf42750b63"
14101145"checksum proc-macro2 1.0.18 (registry+https://github.com/rust-lang/crates.io-index)" = "beae6331a816b1f65d04c45b078fd8e6c93e8071771f41b8163255bbd8d7c8fa"
1411−"checksum proc-quote 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "06ea4226882439d07839be9c7f683e13d6d69d9c2fe960d61f637d1e2fa4c081"
1412−"checksum proc-quote-impl 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7fb3ec628b063cdbcf316e06a8b8c1a541d28fa6c0a8eacd2bfb2b7f49e88aa0"
14131146"checksum quote 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "2bdc6c187c65bca4260c9011c9e3132efe4909da44726bad24cf7572ae338d7f"
14141147"checksum rand 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)" = "552840b97013b1a26992c11eac34bdd778e464601a4c2054b5f0bff7c6761293"
14151148"checksum rand_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6fdeb83b075e8266dcc8762c22776f6877a63111121f5f8c7411e5be7eed4b"
@@ -1430,7 +1163,6 @@ dependencies = [
14301163"checksum serde_derive 1.0.114 (registry+https://github.com/rust-lang/crates.io-index)" = "2a0be94b04690fbaed37cddffc5c134bf537c8e3329d53e982fe04c374978f8e"
14311164"checksum serde_json 1.0.51 (registry+https://github.com/rust-lang/crates.io-index)" = "da07b57ee2623368351e9a0488bb0b261322a15a6e0ae53e243cbdc0f4208da9"
14321165"checksum serde_yaml 0.8.13 (registry+https://github.com/rust-lang/crates.io-index)" = "ae3e2dd40a7cdc18ca80db804b7f461a39bb721160a85c9a1fa30134bf3c02a5"
1433−"checksum sha-1 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)" = "f7d94d0bede923b3cea61f3f1ff57ff8cdfd77b400fb8f9998949e0cf04163df"
14341166"checksum shell-words 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b6fa3938c99da4914afedd13bf3d79bcb6c277d1b2c398d23257a304d9e1b074"
14351167"checksum smallvec 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "05720e22615919e4734f6a99ceae50d00226c3c5aca406e102ebc33298214e0a"
14361168"checksum std_prelude 0.2.12 (registry+https://github.com/rust-lang/crates.io-index)" = "8207e78455ffdf55661170876f88daf85356e4edd54e0a3dbc79586ca1e50cbe"
@@ -1443,13 +1175,9 @@ dependencies = [
14431175"checksum termios 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)" = "6f0fcee7b24a25675de40d5bb4de6e41b0df07bc9856295e7e2b3a3600c400c2"
14441176"checksum textwrap 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d326610f408c7a4eb6f51c37c330e496b08506c9457c9d34287ecc38809fb060"
14451177"checksum thread_local 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d40c6d1b69745a6ec6fb1ca717914848da4b44ae29d9b3080cbee91d72a69b14"
1446−"checksum time 0.1.43 (registry+https://github.com/rust-lang/crates.io-index)" = "ca8a50ef2360fbd1eeb0ecd46795a87a19024eb4b53c5dc916ca1fd95fe62438"
14471178"checksum treeline 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a7f741b240f1a48843f9b8e0444fb55fb2a4ff67293b50a9179dfd5ea67f8d41"
1448−"checksum typenum 1.12.0 (registry+https://github.com/rust-lang/crates.io-index)" = "373c8a200f9e67a0c95e62a4f52fbf80c23b4381c05a17845531982fa99e6b33"
1449−"checksum ucd-trie 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "56dee185309b50d1f11bfedef0fe6d036842e3fb77413abef29f8f8d1c5d4c1c"
14501179"checksum unicode-bidi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "49f2bd0c6468a8230e1db229cff8029217cf623c767ea5d60bfbd42729ea54d5"
14511180"checksum unicode-normalization 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)" = "5479532badd04e128284890390c1e876ef7a993d0570b3597ae43dfa1d59afa4"
1452−"checksum unicode-segmentation 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e83e153d1053cbb5a118eeff7fd5be06ed99153f00dbcd8ae310c5fb2b22edc0"
14531181"checksum unicode-width 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "9337591893a19b88d8d87f2cec1e73fad5cdfd10e5a6f349f498ad6ea2ffb1e3"
14541182"checksum unicode-xid 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "826e7639553986605ec5979c7dd957c7895e93eabed50ab2ffa7f6128a75097c"
14551183"checksum url 2.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "829d4a8476c35c9bf0bbce5a3b23f4106f79728039b726d292bb93bc106787cb"
Cargo.toml+3−5
@@ -25,7 +25,6 @@ application = [
2525 "dirs",
2626 "git",
2727 "lazy_static",
28− "liquid",
2928 "paging",
3029 "wild",
3130 "regex-onig",
@@ -80,8 +79,7 @@ predicates = "1.0.5"
8079
8180[build-dependencies]
8281clap = { version = "2.33", optional = true }
83−liquid = { version = "0.21", optional = true }
8482
85−[profile.release]
86−lto = true
87−codegen-units = 1
83+# [profile.release]
84+# lto = true
85+# codegen-units = 1
assets/manual/bat.1.in+1−1
@@ -1,4 +1,4 @@
1−.TH {{PROJECT_EXECUTABLE | upcase}} "1"
1+.TH {{PROJECT_EXECUTABLE_UPPERCASE}} "1"
22.SH NAME
33{{PROJECT_EXECUTABLE}} \- a cat(1) clone with syntax highlighting and Git integration.
44.SH "USAGE"
build.rs+17−11
@@ -8,6 +8,7 @@ fn main() {}
88
99#[cfg(feature = "application")]
1010fn main() -> Result<(), Box<dyn std::error::Error>> {
11+ use std::collections::HashMap;
1112 use std::error::Error;
1213 use std::fs;
1314 use std::path::Path;
@@ -15,27 +16,32 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
1516 // Read environment variables.
1617 let project_name = option_env!("PROJECT_NAME").unwrap_or("bat");
1718 let executable_name = option_env!("PROJECT_EXECUTABLE").unwrap_or(project_name);
19+ let executable_name_uppercase = executable_name.to_uppercase();
1820 static PROJECT_VERSION: &str = env!("CARGO_PKG_VERSION");
1921
20− /// Generates a file from a liquid template.
22+ /// Generates a file from a template.
2123 fn template(
22− variables: &liquid::Object,
24+ variables: &HashMap<&str, &str>,
2325 in_file: &str,
2426 out_file: impl AsRef<Path>,
2527 ) -> Result<(), Box<dyn Error>> {
26− let template = liquid::ParserBuilder::with_stdlib()
27− .build()?
28− .parse(&fs::read_to_string(in_file)?)?;
28+ let mut content = fs::read_to_string(in_file)?;
2929
30− fs::write(out_file, template.render(variables)?)?;
30+ for (variable_name, value) in variables {
31+ // Replace {{variable_name}} by the value
32+ let pattern = format!("{{{{{variable_name}}}}}", variable_name = variable_name);
33+ content = content.replace(&pattern, value);
34+ }
35+
36+ fs::write(out_file, content)?;
3137 Ok(())
3238 }
3339
34− let variables = liquid::object!({
35− "PROJECT_NAME": project_name,
36− "PROJECT_EXECUTABLE": executable_name,
37− "PROJECT_VERSION": PROJECT_VERSION,
38− });
40+ let mut variables = HashMap::new();
41+ variables.insert("PROJECT_NAME", project_name);
42+ variables.insert("PROJECT_EXECUTABLE", executable_name);
43+ variables.insert("PROJECT_EXECUTABLE_UPPERCASE", &executable_name_uppercase);
44+ variables.insert("PROJECT_VERSION", PROJECT_VERSION);
3945
4046 let out_dir_env = std::env::var_os("OUT_DIR").expect("OUT_DIR to be set in build.rs");
4147 let out_dir = Path::new(&out_dir_env);