X-Git-Url: https://git.phdru.name/?a=blobdiff_plain;ds=sidebyside;f=pep-git.txt;h=968aa329d2f85ba9232ec2e37b3054a6f9af37c6;hb=789c33f68705f65d4c8b480211e972df8dc82e89;hp=d7eb1996f168abe73d025853bcc07402931dce49;hpb=1b42a0f040c366bde1ca0db50b6985d50d87b5d4;p=git-wiki.git diff --git a/pep-git.txt b/pep-git.txt index d7eb199..968aa32 100644 --- a/pep-git.txt +++ b/pep-git.txt @@ -786,10 +786,14 @@ but you can use your editor:: BTW, if git is instructed to use ``less`` as the pager (i.e., if pager is not configured in git at all it uses ``less`` by default, or if it -gets ``less`` from PAGER environment variable, or if it was configured -with ``git config --global core.pager less``, or ``less`` is used in -the command ``git grep -Oless``) ``git grep`` passes ``+/$pattern`` -option to ``less`` which is quite convenient. +gets ``less`` from GIT_PAGER or PAGER environment variables, or if it +was configured with ``git config --global core.pager less``, or +``less`` is used in the command ``git grep -Oless``) ``git grep`` +passes ``+/$pattern`` option to ``less`` which is quite convenient. +Unfortunately, ``git grep`` doesn't pass the pattern if the pager is +not exactly ``less``, even if it's ``less`` with parameters (something +like ``git config --global core.pager less -FRSXgimq``); fortunately, +``git grep -Oless`` always passes the pattern. bash/zsh completion