grep.txt 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. * Introduction -*-grep-*- (See the end of file for copyright information)
  2. This shows the different kinds of messages grep recognizes by default and
  3. how they are rendered. It is intended both to help you decide which matchers
  4. you need and as a test of the matchers. Move the mouse over a colored part
  5. to see how much text was actually matched.
  6. Please do not edit this file in grep-mode, it may lose escape
  7. sequences on saving. Visit this file literally for editing.
  8. * GNU grep 2.5.1
  9. grep -nH -e "INFO tree" ../info/*
  10. ../info/dir:6:File: dir Node: Top This is the top of the INFO tree
  11. * GNU grep 2.5.1 with default colors
  12. grep -nH --color=always -e "INFO tree" ../info/*
  13. ../info/dir:6:File: dir Node: Top This is the top of the INFO tree
  14. * GNU grep 2.5.1-cvs with the specified matching color
  15. GREP_COLORS='mt=01;31:fn=:ln=:bn=:se=:ml=:cx=:ne' grep -nH --color=always -e "INFO tree" ../info/*
  16. ../info/dir:6:File: dir Node: Top This is the top of the INFO tree
  17. * GNU grep 2.5.1-cvs with colors for the file name, line number and match
  18. GREP_COLORS='mt=01;31:fn=35:ln=32:bn=:se=:ml=36:cx=37:ne' grep -nH --color=always -e "INFO tree" ../info/*
  19. ../info/dir:6:File: dir Node: Top This is the top of the INFO tree
  20. 1:2:3:4:text
  21. 1:2:3:4:text
  22. 1:2:3:4:text
  23. * GNU grep 2.5.1-cvs with default colors
  24. grep -nH --color=always -e "INFO tree" ../info/*
  25. ../info/dir:6:File: dir Node: Top This is the top of the INFO tree
  26. * GNU grep 2.5.1 on lines starting with a number and colon
  27. grep -nH -e "Universal Time" ../lispref/*
  28. ../lispref/os.texi:1010:0:00 January 1, 1970 UTC (Coordinated Universal Time)
  29. * GNU grep 2.5.1 with context lines
  30. grep -C 2 -nH --color=always -e "INFO tree" ../info/*
  31. ../info/dir-4-looking at that node, which is (dir)Top.
  32. ../info/dir-5-
  33. ../info/dir:6:File: dir Node: Top This is the top of the INFO tree
  34. ../info/dir-7-
  35. ../info/dir-8-The Info Directory
  36. * GNU grep 2.5.1 on files recognized as binary
  37. Binary file emacs-7 matches
  38. Binary file 2005-06 matches
  39. * GNU grep 2.5.1: other messages
  40. Grep started at Tue Jul 19 15:41:30
  41. grep: ../info/dirinfo: No such file or directory
  42. Grep interrupt at Tue Jul 19 15:42:31
  43. Grep killed at Tue Jul 19 15:42:31
  44. Grep terminated at Tue Jul 19 15:42:31
  45. Grep exited abnormally with code 2 at Tue Jul 19 15:42:31
  46. Grep finished with no matches found at Tue Jul 19 15:43:12
  47. Grep finished (matches found) at Thu Jul 21 15:02:15
  48. * agrep
  49. agrep -n "INFO tree" ../info/*
  50. ../info/dir: 6: File: dir Node: Top This is the top of the INFO tree
  51. * unknown greps
  52. grep -nH -e "xyzxyz" ../info/*
  53. ../info/emacs-2:1205:10:inserts `xyzxyzxyzxyz' in the current buffer.
  54. ../info/emacs-2:1205:10-15:inserts `xyzxyzxyzxyz' in the current buffer.
  55. ../info/emacs-2:1205.10-1205.15:inserts `xyzxyzxyzxyz' in the current buffer.
  56. ../info/emacs-2 1205.10-15 inserts `xyzxyzxyzxyz' in the current buffer.
  57. ../info/emacs-2 1205.10-1205.15 inserts `xyzxyzxyzxyz' in the current buffer.
  58. ../info/emacs-2 1205 inserts `xyzxyzxyzxyz' in the current buffer.
  59. Copyright (C) 2005-2012 Free Software Foundation, Inc.
  60. COPYING PERMISSIONS:
  61. This document is free software: you can redistribute it and/or modify
  62. it under the terms of the GNU General Public License as published by
  63. the Free Software Foundation, either version 3 of the License, or
  64. (at your option) any later version.
  65. This program is distributed in the hope that it will be useful,
  66. but WITHOUT ANY WARRANTY; without even the implied warranty of
  67. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  68. GNU General Public License for more details.
  69. You should have received a copy of the GNU General Public License
  70. along with this program. If not, see <http://www.gnu.org/licenses/>.
  71. ;;; Local Variables:
  72. ;;; eval: (let ((inhibit-read-only t) (compilation-filter-start (point-min))) (save-excursion (goto-char (point-max)) (grep-filter) (set-buffer-modified-p nil)))
  73. ;;; buffer-read-only: t
  74. ;;; End: