1 | %define pkg_name the_silver_searcher |
---|
2 | %define pkg_version 2.2.0 |
---|
3 | %define pkg_release 1%{?_dist_release} |
---|
4 | |
---|
5 | Summary: ag: The silver searcher |
---|
6 | Summary(ja): ag: 高速検索プログラム |
---|
7 | Name: silversearcher-ag |
---|
8 | Version: %{pkg_version} |
---|
9 | Release: %{pkg_release} |
---|
10 | License: Apache License 2.0 |
---|
11 | |
---|
12 | Group: Applications/Accessories |
---|
13 | URL: https://github.com/ggreer/the_silver_searcher |
---|
14 | Source: %{pkg_name}-%{pkg_version}.tar.gz |
---|
15 | |
---|
16 | BuildRoot: %{_tmppath}/%{name}-%{version}-root |
---|
17 | BuildRequires: pcre-devel xz-devel zlib-devel |
---|
18 | Requires: pcre xz zlib |
---|
19 | |
---|
20 | Conflicts: the_silver_searcher |
---|
21 | |
---|
22 | Vendor: Project Vine |
---|
23 | Distribution: Vine Linux |
---|
24 | Packager: ara_t |
---|
25 | |
---|
26 | |
---|
27 | %description |
---|
28 | The Silver Searcher |
---|
29 | An attempt to make something better than ack |
---|
30 | (which itself is better than grep). |
---|
31 | |
---|
32 | Why use Ag? |
---|
33 | * It searches code about 3–5x faster than ack. |
---|
34 | * It ignores file patterns from your .gitignore and .hgignore. |
---|
35 | * If there are files in your source repo you don't want to search, |
---|
36 | just add their patterns to a .agignore file. *cough* extern *cough* |
---|
37 | * The command name is 33% shorter than ack! |
---|
38 | |
---|
39 | How is it so fast? |
---|
40 | * Searching for literals (no regex) uses Boyer-Moore-Horspool strstr. |
---|
41 | * Files are mmap()ed instead of read into a buffer. |
---|
42 | * If you're building with PCRE 8.21 or greater, |
---|
43 | regex searches use the JIT compiler. |
---|
44 | * Ag calls pcre_study() before executing the regex on a jillion files. |
---|
45 | * Instead of calling fnmatch() on every pattern in your ignore files, |
---|
46 | non-regex patterns are loaded into an array and binary searched. |
---|
47 | * Ag uses Pthreads to take advantage of multiple CPU cores and |
---|
48 | search files in parallel. |
---|
49 | |
---|
50 | %description -l ja |
---|
51 | The Silver Searcher: 高速検索プログラム |
---|
52 | * ackより3-5倍高速 |
---|
53 | * .gitignore、.hgignoreに記載されているものを検索対象から除外 |
---|
54 | * 検索対象から除外したいファイルは.agignoreに記載 |
---|
55 | * agというコマンド名で、ackと比べてコマンドが短い(33%減!) |
---|
56 | |
---|
57 | |
---|
58 | %prep |
---|
59 | %{__rm} -rf ${RPM_BUILD_ROOT} |
---|
60 | %setup -q -n %{pkg_name}-%{pkg_version} |
---|
61 | |
---|
62 | ./build.sh |
---|
63 | %{configure} |
---|
64 | |
---|
65 | %build |
---|
66 | %{__make} %{?_smp_mflags} |
---|
67 | |
---|
68 | %install |
---|
69 | %{make_install} |
---|
70 | |
---|
71 | %clean |
---|
72 | %{__rm} -rf ${RPM_BUILD_ROOT} |
---|
73 | |
---|
74 | |
---|
75 | %files |
---|
76 | %defattr(-, root, root) |
---|
77 | %{_bindir}/ |
---|
78 | %{_datadir}/ |
---|
79 | |
---|
80 | |
---|
81 | %changelog |
---|
82 | * Wed Aug 08 2018 Toshiaki Ara <ara_t@384.jp> 2.2.0-1 |
---|
83 | - new upstream release |
---|
84 | - add Conflicts: the_silver_searcher |
---|
85 | |
---|
86 | * Tue Aug 29 2017 Toshiaki Ara <ara_t@384.jp> 2.1.0-1 |
---|
87 | - new upstream release |
---|
88 | |
---|
89 | * Wed Jun 07 2017 Toshiaki Ara <ara_t@384.jp> 2.0.0-1 |
---|
90 | - new upstream release |
---|
91 | |
---|
92 | * Fri May 05 2017 Toshiaki Ara <ara_t@384.jp> 1.0.3-1 |
---|
93 | - new upstream release |
---|
94 | |
---|
95 | * Tue Dec 06 2016 Toshiaki Ara <ara_t@384.jp> 1.0.2-1 |
---|
96 | - new upstream release |
---|
97 | |
---|
98 | * Mon Nov 28 2016 Toshiaki Ara <ara_t@384.jp> 1.0.1-1 |
---|
99 | - new upstream release |
---|
100 | |
---|
101 | * Mon Oct 10 2016 Toshiaki Ara <ara_t@384.jp> 0.33.0-1 |
---|
102 | - update to 0.33.0 |
---|
103 | |
---|
104 | * Tue May 17 2016 Toshiaki Ara <ara_t@384.jp> 0.32.0-1 |
---|
105 | - update to 0.32.0 |
---|
106 | |
---|
107 | * Sun Apr 10 2016 Toshiaki Ara <ara_t@384.jp> 0.31.0-3 |
---|
108 | - correct SPEC file |
---|
109 | |
---|
110 | * Wed Feb 17 2016 Toshiaki Ara <ara_t@384.jp> 0.31.0-2 |
---|
111 | - add LICENSE |
---|
112 | |
---|
113 | * Tue Sep 22 2015 Toshiaki Ara <ara_t@384.jp> 0.31.0-1 |
---|
114 | - new package |
---|
115 | |
---|