1. 23 7月, 2009 1 次提交
    • M
      grep: Add --max-depth option. · a91f453f
      Michał Kiedrowicz 提交于
      It is useful to grep directories non-recursively, e.g. when one wants to
      look for all files in the toplevel directory, but not in any subdirectory,
      or in Documentation/, but not in Documentation/technical/.
      
      This patch adds support for --max-depth <depth> option to git-grep. If it is
      given, git-grep descends at most <depth> levels of directories below paths
      specified on the command line.
      
      Note that if path specified on command line contains wildcards, this option
      makes no sense, e.g.
      
          $ git grep -l --max-depth 0 GNU -- 'contrib/*'
      
      (note the quotes) will search all files in contrib/, even in
      subdirectories, because '*' matches all files.
      
      Documentation updates, bash-completion and simple test cases are also
      provided.
      Signed-off-by: NMichał Kiedrowicz <michal.kiedrowicz@gmail.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      a91f453f
  2. 02 7月, 2009 2 次提交
  3. 08 3月, 2009 1 次提交
    • R
      grep: color patterns in output · 7e8f59d5
      René Scharfe 提交于
      Coloring matches makes them easier to spot in the output.
      
      Add two options and two parameters: color.grep (to turn coloring on
      or off), color.grep.match (to set the color of matches), --color
      and --no-color (to turn coloring on or off, respectively).
      
      The output of external greps is not changed.
      
      This patch is based on earlier ones by Nguyễn Thái Ngọc Duy and
      Thiago Alves.
      Signed-off-by: NRene Scharfe <rene.scharfe@lsrfire.ath.cx>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      7e8f59d5
  4. 02 10月, 2008 1 次提交
  5. 06 7月, 2008 1 次提交
  6. 02 7月, 2008 2 次提交
    • J
      Documentation formatting and cleanup · 483bc4f0
      Jonathan Nieder 提交于
      Following what appears to be the predominant style, format
      names of commands and commandlines both as `teletype text`.
      
      While we're at it, add articles ("a" and "the") in some
      places, italicize the name of the command in the manual page
      synopsis line, and add a comma or two where it seems appropriate.
      Signed-off-by: NJonathan Nieder <jrnieder@uchicago.edu>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      483bc4f0
    • J
      Documentation: be consistent about "git-" versus "git " · b1889c36
      Jonathan Nieder 提交于
      Since the git-* commands are not installed in $(bindir), using
      "git-command <parameters>" in examples in the documentation is
      not a good idea. On the other hand, it is nice to be able to
      refer to each command using one hyphenated word. (There is no
      escaping it, anyway: man page names cannot have spaces in them.)
      
      This patch retains the dash in naming an operation, command,
      program, process, or action. Complete command lines that can
      be entered at a shell (i.e., without options omitted) are
      made to use the dashless form.
      
      The changes consist only of replacing some spaces with hyphens
      and vice versa. After a "s/ /-/g", the unpatched and patched
      versions are identical.
      Signed-off-by: NJonathan Nieder <jrnieder@uchicago.edu>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      b1889c36
  7. 09 6月, 2008 1 次提交
    • S
      Docs: Use "-l::\n--long\n" format in OPTIONS sections · 3240240f
      Stephan Beyer 提交于
      The OPTIONS section of a documentation file contains a list
      of the options a git command accepts.
      
      Currently there are several variants to describe the case that
      different options (almost) do the same in the OPTIONS section.
      
      Some are:
      
       -f, --foo::
       -f|--foo::
       -f | --foo::
      
      But AsciiDoc has the special form:
      
       -f::
       --foo::
      
      This patch applies this form to the documentation of the whole git suite,
      and removes useless em-dash prevention, so \--foo becomes --foo.
      Signed-off-by: NStephan Beyer <s-beyer@gmx.net>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      3240240f
  8. 07 6月, 2008 1 次提交
  9. 03 3月, 2008 1 次提交
  10. 21 2月, 2008 1 次提交
  11. 07 1月, 2008 1 次提交
    • D
      Documentation: rename gitlink macro to linkgit · 5162e697
      Dan McGee 提交于
      Between AsciiDoc 8.2.2 and 8.2.3, the following change was made to the stock
      Asciidoc configuration:
      
      @@ -149,7 +153,10 @@
       # Inline macros.
       # Backslash prefix required for escape processing.
       # (?s) re flag for line spanning.
      -(?su)[\\]?(?P<name>\w(\w|-)*?):(?P<target>\S*?)(\[(?P<attrlist>.*?)\])=
      +
      +# Explicit so they can be nested.
      +(?su)[\\]?(?P<name>(http|https|ftp|file|mailto|callto|image|link)):(?P<target>\S*?)(\[(?P<attrlist>.*?)\])=
      +
       # Anchor: [[[id]]]. Bibliographic anchor.
       (?su)[\\]?\[\[\[(?P<attrlist>[\w][\w-]*?)\]\]\]=anchor3
       # Anchor: [[id,xreflabel]]
      
      This default regex now matches explicit values, and unfortunately in this
      case gitlink was being matched by just 'link', causing the wrong inline
      macro template to be applied. By renaming the macro, we can avoid being
      matched by the wrong regex.
      Signed-off-by: NDan McGee <dpmcgee@gmail.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      5162e697
  12. 07 6月, 2007 1 次提交
    • J
      War on whitespace · a6080a0a
      Junio C Hamano 提交于
      This uses "git-apply --whitespace=strip" to fix whitespace errors that have
      crept in to our source files over time.  There are a few files that need
      to have trailing whitespaces (most notably, test vectors).  The results
      still passes the test, and build result in Documentation/ area is unchanged.
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      a6080a0a
  13. 27 4月, 2007 1 次提交
  14. 18 1月, 2007 1 次提交
  15. 28 9月, 2006 1 次提交
    • J
      grep --all-match · 0ab7befa
      Junio C Hamano 提交于
      This lets you say:
      
      	git grep --all-match -e A -e B -e C
      
      to find lines that match A or B or C but limit the matches from
      the files that have all of A, B and C.
      
      This is different from
      
      	git grep -e A --and -e B --and -e C
      
      in that the latter looks for a single line that has all of these
      at the same time.
      Signed-off-by: NJunio C Hamano <junkio@cox.net>
      0ab7befa
  16. 16 9月, 2006 1 次提交
  17. 12 8月, 2006 1 次提交
  18. 03 8月, 2006 1 次提交
  19. 26 6月, 2006 1 次提交
  20. 04 6月, 2006 1 次提交
  21. 10 5月, 2006 1 次提交
  22. 09 5月, 2006 1 次提交
  23. 23 3月, 2006 1 次提交
  24. 10 3月, 2006 1 次提交
  25. 22 1月, 2006 1 次提交
    • J
      git-grep: clarification on parameters. · 5b2bcc7b
      Junio C Hamano 提交于
      We forgot to make sure that there is no more than one pattern
      parameter.  Also when looking for files in a directory called
      '--others', it passed that path limiter without preceding the
      end-of-options marker '--' to underlying git-ls-files, which
      misunderstood it as one of its options instead.
      
      	$ git grep --others -e Meta/Make Meta
      	$ git grep -o -e Meta/Make Meta
      	$ git grep -o Meta/Make Meta
      
      look for a string "Meta/Make" from untracked files in Meta/
      directory.
      
      	$ git grep Meta/Make --others
      
      looks for the same string from tracked files in ./--others
      directory.
      
      On the other hand,
      
      	$ git grep -e Meta/Make --others
      
      does not have a freestanding pattern, so everybody is parameter
      and there is no path specifier.  It looks for the string in all
      the untracked files without any path limiter.
      
      [jc: updated with usability enhancements and documentation
      cleanups from Sean.]
      Signed-off-by: NJunio C Hamano <junkio@cox.net>
      5b2bcc7b
  26. 06 1月, 2006 1 次提交
  27. 11 10月, 2005 1 次提交
  28. 21 9月, 2005 1 次提交
  29. 13 9月, 2005 1 次提交