all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Federico Tedin <federicotedin@gmail.com>
To: Noam Postavsky <npostavs@gmail.com>
Cc: 32549@debbugs.gnu.org
Subject: bug#32549: Allow passing custom options to vc-git-grep
Date: Tue, 28 Aug 2018 20:31:25 -0300	[thread overview]
Message-ID: <CAA8GjP=ws1_P0SYastHtXQeMy7ioHJo5dcJdbQ+U_ytL1SSPTA@mail.gmail.com> (raw)
In-Reply-To: <8736uyt767.fsf@gmail.com>

> Doesn't projectile-grep prompt you for a regexp?  I don't have it
> installed here, but it looks like you have to pass a non-nil ARG to get
> prompted for filenames, i.e.,
>
>   (let ((current-prefix-arg '(4)))
>     (projectile-grep nil t))

My mistake. Calling projectile-grep with current-prefix-arg '(4) indeed prompts
for the git-grep command _and_ a regexp.

> > Is there any way to set a default set of arguments in order to avoid
> > typing them when invoking the function?
>
> Not sure I follow, when you pass "something" and "*.el" to the function,
> those get inserted into the default command so you don't have to type
> them interactively.

I am sorry if I wasn't clear enough. What I'm trying to say is, when calling
vc-git-grep directly or indirectly with current-prefix-arg '(4), I am always
prompted for the full git-grep command. I would like to skip this step
completely,
and always use a custom set of arguments (like, for example, "-C 3"). Then, I
would be prompted for a regexp and (maybe) files, which would be added to this
custom git-grep command's arguments (this is how the rgrep command works, I
think).





  reply	other threads:[~2018-08-28 23:31 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-27 23:03 bug#32549: Allow passing custom options to vc-git-grep Federico Tedin
2018-08-27 23:20 ` Noam Postavsky
2018-08-28  2:55   ` Federico Tedin
2018-08-28  3:52     ` Noam Postavsky
2018-08-28 23:01       ` Federico Tedin
2018-08-28 23:14         ` Noam Postavsky
2018-08-28 23:31           ` Federico Tedin [this message]
2018-08-29  0:45             ` Noam Postavsky
2018-08-29  0:54               ` Federico Tedin
2018-09-01 21:55                 ` Federico Tedin
2018-09-04 23:03                   ` Noam Postavsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAA8GjP=ws1_P0SYastHtXQeMy7ioHJo5dcJdbQ+U_ytL1SSPTA@mail.gmail.com' \
    --to=federicotedin@gmail.com \
    --cc=32549@debbugs.gnu.org \
    --cc=npostavs@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.