Ag, the Silver Searcher, compiles and runs in cygwin without any problems!
来源:互联网 发布:大胸怎么穿衣服知乎 编辑:程序博客网 时间:2024/04/27 22:14
Ag, the Silver Searcher, compiles and runs in cygwin without any problems!
ggreer/the_silver_searcher
https://github.com/ggreer/the_silver_searcher
The Silver Searcher (ag.exe) how to build Windows Cygwin environment - Geek of Nooblog
http://geekna.hatenablog.jp/entry/20130531/p1
cygwin even I tried to put silver searcher (ag) - PILOG
http://xoyip.hatenablog.com/entry/2014/08/09/200000
Cygwin利用apt-cyg安装gcc、g++、make和gdb - yuanshuilee的日志 - 网易博客
http://yuanshuilee.blog.163.com/blog/static/217697275201412672227185/
Cygwin下面,apt-cyg的使用方法和基本原理 - yuanshuilee的日志 - 网易博客
http://yuanshuilee.blog.163.com/blog/static/2176972752014126786185/
Index of /cygwin/x86/
http://mirrors.163.com/cygwin/x86/
○○○○ there 's no one is scary to! ! : I introduce the apt-cyg in Cygwin
http://kowaimononantenai.blogspot.jp/2013/12/cygwinapt-cyg.html
The Silver Searcher windows port
http://blog.kowalczyk.info/software/the-silver-searcher-for-windows.html
Download :
Download latest version 0.18.1-1129 (built on 2014-01-03):
- ag.exe
- ag.zip
Sources are at https://github.com/kjk/the_silver_searcher
Installation steps:
Add packages: automake pkg-config libpcre-devel liblzma-dev1. git clone https://github.com/ggreer/the_silver_searcher.git
2. cd the_silver_searcher && ./build.sh && make install
liango@Lenovo-PC /usr/local/src$ git clone https://github.com/ggreer/the_silver_searcher.git正克隆到 'the_silver_searcher'...remote: Counting objects: 5766, done.remote: Total 5766 (delta 0), reused 0 (delta 0)接收对象中: 100% (5766/5766), 1.57 MiB | 176.00 KiB/s, 完成.处理 delta 中: 100% (3215/3215), 完成.检查连接... 完成。liango@Lenovo-PC /usr/local/src$ cd the_silver_searcher && ./build.sh && make installconfigure.ac:10: installing './compile'configure.ac:21: installing './config.guess'configure.ac:21: installing './config.sub'configure.ac:8: installing './install-sh'configure.ac:8: installing './missing'Makefile.am: installing './depcomp'checking for a BSD-compatible install... /usr/bin/install -cchecking whether build environment is sane... yeschecking for a thread-safe mkdir -p... /usr/bin/mkdir -pchecking for gawk... gawkchecking whether make sets $(MAKE)... yeschecking whether make supports nested variables... yeschecking for gcc... gccchecking whether the C compiler works... yeschecking for C compiler default output file name... a.exechecking for suffix of executables... .exechecking whether we are cross compiling... nochecking for suffix of object files... ochecking whether we are using the GNU C compiler... yeschecking whether gcc accepts -g... yeschecking for gcc option to accept ISO C89... none neededchecking whether gcc understands -c and -o together... yeschecking for style of include used by make... GNUchecking dependency style of gcc... gcc3checking whether make supports nested variables... (cached) yeschecking for pkg-config... /usr/bin/pkg-configchecking pkg-config is at least version 0.9.0... yeschecking for PCRE... yeschecking build system type... i686-pc-cygwinchecking host system type... i686-pc-cygwinchecking how to run the C preprocessor... gcc -Echecking for grep that handles long lines and -e... /usr/bin/grepchecking for egrep... /usr/bin/grep -Echecking for ANSI C header files... yeschecking for sys/types.h... yeschecking for sys/stat.h... yeschecking for stdlib.h... yeschecking for string.h... yeschecking for memory.h... yeschecking for strings.h... yeschecking for inttypes.h... yeschecking for stdint.h... yeschecking for unistd.h... yeschecking if compiler needs -Werror to reject unknown flags... nochecking for the pthreads library -lpthreads... nochecking whether pthreads work without any flags... yeschecking for joinable pthread attribute... PTHREAD_CREATE_JOINABLEchecking if more special flags are required for pthreads... nochecking for PTHREAD_PRIO_INHERIT... nochecking pthread.h usability... yeschecking pthread.h presence... yeschecking for pthread.h... yeschecking zlib.h usability... yeschecking zlib.h presence... yeschecking for zlib.h... yeschecking for library containing inflate... -lzchecking lzma.h usability... yeschecking lzma.h presence... yeschecking for lzma.h... yeschecking for LZMA... yeschecking whether PCRE_CONFIG_JIT is declared... yeschecking for struct dirent.d_type... yeschecking for fgetln... nochecking for getline... yeschecking for realpath... yeschecking for strlcpy... yeschecking for strndup... yeschecking for vasprintf... yeschecking for madvise... yeschecking for posix_fadvise... yeschecking that generated files are newer than configure... doneconfigure: creating ./config.statusconfig.status: creating Makefileconfig.status: creating the_silver_searcher.specconfig.status: creating src/config.hconfig.status: executing depfiles commands CC src/ignore.o CC src/log.o CC src/options.o CC src/print.osrc/ignore.c: 在函数‘add_ignore_pattern’中:src/ignore.c:101:9: 警告:数组下标类型为‘char’ [-Wchar-subscripts] if (!isspace(pattern[pattern_len - 1])) { ^src/print.c: 在函数‘print_path_count’中:src/print.c:37:9: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 4 has type ‘size_t’ [-Wformat=] fprintf(out_fd, "%s%lu%s%c", opts.color_line_number, count, color_reset, sep); ^src/print.c:37:9: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 4 has type ‘size_t’ [-Wformat=]src/print.c:39:9: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘size_t’ [-Wformat=] fprintf(out_fd, "%lu%c", count, sep); ^src/print.c:39:9: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘size_t’ [-Wformat=]src/print.c: 在函数‘print_file_matches’中:src/print.c:153:33: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘unsigned int’ [-Wformat=] (matches[last_printed_match].end - matches[last_printed_match].start)); ^src/print.c:153:33: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 4 has type ‘unsigned int’ [-Wformat=]src/print.c:153:33: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘unsigned int’ [-Wformat=]src/print.c:153:33: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 4 has type ‘unsigned int’ [-Wformat=]src/print.c: 在函数‘print_column_number’中:src/print.c:247:13: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘unsigned int’ [-Wformat=] sep); ^src/print.c:247:13: 警告:格式 ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘unsigned int’ [-Wformat=] CC src/scandir.o CC src/search.o CC src/lang.o CC src/util.o CC src/decompress.o CC src/main.osrc/util.c: 在函数‘generate_alpha_skip’中:src/util.c:68:13: 警告:数组下标类型为‘char’ [-Wchar-subscripts] skip_lookup[(unsigned char)tolower(find[i])] = f_len - i; ^src/util.c:69:13: 警告:数组下标类型为‘char’ [-Wchar-subscripts] skip_lookup[(unsigned char)toupper(find[i])] = f_len - i; ^src/util.c: 在函数‘is_prefix’中:src/util.c:83:13: 警告:数组下标类型为‘char’ [-Wchar-subscripts] if (tolower(s[i]) != tolower(s[i + pos])) { ^src/util.c:83:13: 警告:数组下标类型为‘char’ [-Wchar-subscripts]src/util.c: 在函数‘suffix_len’中:src/util.c:101:13: 警告:数组下标类型为‘char’ [-Wchar-subscripts] if (tolower(s[pos - i]) != tolower(s[s_len - i - 1])) { ^src/util.c:101:13: 警告:数组下标类型为‘char’ [-Wchar-subscripts]src/util.c: 在函数‘boyer_moore_strncasestr’中:src/util.c:164:9: 警告:数组下标类型为‘char’ [-Wchar-subscripts] for (i = f_len - 1; i >= 0 && tolower(s[pos]) == find[i]; pos--, i--) { ^src/util.c: 在函数‘is_lowercase’中:src/util.c:388:9: 警告:数组下标类型为‘char’ [-Wchar-subscripts] if (!isascii(s[i]) || isupper(s[i])) { ^src/main.c: 在函数‘main’中:src/main.c:102:17: 警告:数组下标类型为‘char’ [-Wchar-subscripts] *c = (char)tolower(*c); ^ CCLD ag.exemake[1]: Entering directory '/usr/local/src/the_silver_searcher' /usr/bin/mkdir -p '/usr/local/bin' /usr/bin/install -c ag.exe '/usr/local/bin' /usr/bin/mkdir -p '/usr/local/share/the_silver_searcher/completions' /usr/bin/install -c -m 644 ag.bashcomp.sh '/usr/local/share/the_silver_searcher/completions' /usr/bin/mkdir -p '/usr/local/share/man/man1' /usr/bin/install -c -m 644 doc/ag.1 '/usr/local/share/man/man1'make[1]: Leaving directory '/usr/local/src/the_silver_searcher'liango@Lenovo-PC /usr/local/src/the_silver_searcher$ lsaclocal.m4 autom4te.cache config.guess config.sub depcomp install-sh Makefile Makefile.w32 README.md the_silver_searcher.specag.bashcomp.sh build.sh config.log configure doc LICENSE Makefile.am missing src the_silver_searcher.spec.inag.exe compile config.status configure.ac format.sh m4 Makefile.in NOTICE tests
$ which ag/usr/local/bin/agliango@Lenovo-PC /usr/local/src/the_silver_searcher$ agUsage: ag [FILE-TYPE] [OPTIONS] PATTERN [PATH] Recursively search for PATTERN in PATH. Like grep or ack, but faster.Example: ag -i foo /bar/Output Options: --ackmate Print results in AckMate-parseable format -A --after [LINES] Print lines after match (Default: 2) -B --before [LINES] Print lines before match (Default: 2) --[no]break Print newlines between matches in different files (Enabled by default) -c --count Only print the number of matches in each file. (This often differs from the number of matching lines) --[no]color Print color codes in results (Enabled by default) --color-line-number Color codes for line numbers (Default: 1;33) --color-match Color codes for result match numbers (Default: 30;43) --color-path Color codes for path names (Default: 1;32) --column Print column numbers in results -H --[no]heading Print file names (Enabled unless searching a single file) --line-numbers Print line numbers even for streams -C --context [LINES] Print lines before and after matches (Default: 2) --[no]group Same as --[no]break --[no]heading -g PATTERN Print filenames matching PATTERN -l --files-with-matches Only print filenames that contain matches (don't print the matching lines) -L --files-without-matches Only print filenames that don't contain matches --no-numbers Don't print line numbers --print-long-lines Print matches on very long lines (Default: >2k characters) --passthrough When searching a stream, print all lines even if they don't match --silent Suppress all log messages, including errors --stats Print stats (files scanned, time taken, etc.) --vimgrep Print results like vim's :vimgrep /pattern/g would (it reports every match on the line) -0 --null --print0 Separate filenames with null (for 'xargs -0')Search Options: -a --all-types Search all files (doesn't include hidden files or patterns from ignore files) -D --debug Ridiculous debugging (probably not useful) --depth NUM Search up to NUM directories deep (Default: 25) -f --follow Follow symlinks -G --file-search-regex PATTERN Limit search to filenames matching PATTERN --hidden Search hidden files (obeys .*ignore files) -i --ignore-case Match case insensitively --ignore PATTERN Ignore files/directories matching PATTERN (literal file/directory names also allowed) --ignore-dir NAME Alias for --ignore for compatibility with ack. -m --max-count NUM Skip the rest of a file after NUM matches (Default: 10,000) -p --path-to-agignore STRING Use .agignore file at STRING -Q --literal Don't parse PATTERN as a regular expression -s --case-sensitive Match case sensitively -S --smart-case Match case insensitively unless PATTERN contains uppercase characters (Enabled by default) --search-binary Search binary files for matches -t --all-text Search all text files (doesn't include hidden files) -u --unrestricted Search all files (ignore .agignore, .gitignore, etc.; searches binary and hidden files as well) -U --skip-vcs-ignores Ignore VCS ignore files (.gitignore, .hgignore, .svnignore; still obey .agignore) -v --invert-match -w --word-regexp Only match whole words -z --search-zip Search contents of compressed (e.g., gzip) filesFile Types:The search can be restricted to certain types of files. Example: ag --html needle - Searches for 'needle' in files with suffix .htm, .html, .shtml or .xhtml.For a list of supported file types run: ag --list-file-typesliango@Lenovo-PC /usr/local/src/the_silver_searcher$
参考:
Ag, the Silver Searcher, compiles and runs in cygwin without any problems! …
https://plus.google.com/+SaadMalik/posts/EE6ZWcesWip
apt get - apt-get for cygwin? - Stack Overflow
http://stackoverflow.com/questions/9751845/apt-get-for-cygwin
transcode-open/apt-cyg
ggreer/the_silver_searcher
https://github.com/ggreer/the_silver_searcher
http://geekna.hatenablog.jp/entry/20130531/p1
cygwin even I tried to put silver searcher (ag) - PILOG
http://xoyip.hatenablog.com/entry/2014/08/09/200000
Cygwin利用apt-cyg安装gcc、g++、make和gdb - yuanshuilee的日志 - 网易博客
http://yuanshuilee.blog.163.com/blog/static/217697275201412672227185/
Cygwin下面,apt-cyg的使用方法和基本原理 - yuanshuilee的日志 - 网易博客
http://yuanshuilee.blog.163.com/blog/static/2176972752014126786185/
Index of /cygwin/x86/
http://mirrors.163.com/cygwin/x86/
○○○○ there 's no one is scary to! ! : I introduce the apt-cyg in Cygwin
http://kowaimononantenai.blogspot.jp/2013/12/cygwinapt-cyg.html
The Silver Searcher windows port
http://blog.kowalczyk.info/software/the-silver-searcher-for-windows.html
1 0
- Ag, the Silver Searcher, compiles and runs in cygwin without any problems!
- Ag(The Silver Searcher)相关
- Mac下安装HomeBrew和Ag(the silver searcher)
- Get the SharePoint groups in Infopath 2010 and SharePoint 2010 by current user without any code
- ag(The silver search)的使用
- The silver search(ag)比ack-grep还快
- Problems and Projections in CS for the Next 49 Years
- 比 ack-grep 更快更好用的东东:the silver searcher
- 用the silver searcher与alfred从一堆文件中快速查找信息
- How do you remove the duplicate characters in a given string without using any additional buffer.
- HAX is not working and emulator runs in emulation mode
- HAX is not working and emulator runs in emulation mode
- HAX is not working and emulator runs in emulation mode
- HAXM is working and emulator runs in fast virt mode
- HAXM is not working and emulator runs in emulation mode
- HAX is not working and emulator runs in emulation mode
- In the beginning, the world was void and without form…
- Conquering the Most Difficult Problems in China and Asia — Ethan Soo in Agile Tour 2010 Hangzhou
- Huffman树的应用 (数据结构)
- 动态申请二维数组
- 《C++入门经典》读书笔记+习题解答 第10章 程序文件和预处理器指令
- Java Web 简介,MyEclipse介绍,MyEclipse中配置自己的jre以及tomcat
- 在谈数位dp_用记忆优化解决无法递推的题目
- Ag, the Silver Searcher, compiles and runs in cygwin without any problems!
- TCP/IP协议族(二):域名系统介绍(一)(DNS)
- Quartus II调用modelsim无缝仿真
- java学习笔记 2014/12/5
- 从大学往小时候眺望
- ORACLE ASM环境中删除和创建表空间、增加表空间数据文件
- tomcat/webapps目录下必须存放project而不能是文件
- 关于Tcp封包
- bzoj3143: [Hnoi2013]游走 高斯消元求概率