Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

arguments to rg (rg-l) #85

Open
agtonybarletta opened this issue May 8, 2020 · 5 comments
Open

arguments to rg (rg-l) #85

agtonybarletta opened this issue May 8, 2020 · 5 comments

Comments

@agtonybarletta
Copy link

Is there a way to pass arguments to rg?

Since the grep command uses rg, can we pass argument to rg within the extension?
I would like to simulate the behaviour of rg -l using CocList

:CocList grep -l
@chemzqm
Copy link
Member

chemzqm commented May 8, 2020

It should work by use fullname of option

@agtonybarletta
Copy link
Author

agtonybarletta commented May 8, 2020

Configuration:

  • Windows 10
  • rg: Ripgrep-All 0.9.3 (chocolatey)
  • vim version: NVIM v0.5.0-435-ge11e93d13
  • node version: v12.16.1
  • coc.nvim version: 0.0.77-817efd5108
  • term: vtpcon
  • platform: win32

If I run :CocList grep --files-with-matches it doesn't show anything.
The command >rg -files-with-matches <string> run with cmd.exe works as expected.

@chemzqm
Copy link
Member

chemzqm commented May 8, 2020

You should use files source for grep files

@agtonybarletta
Copy link
Author

What do you mean with "files source"?
My intention is to search for a word within the content of the files and then list the file names only (not the content that matches the word). In this way I will have one line for each file matched ( one line for each file that contains the searched word) and not one line for each match in the file.

@chemzqm
Copy link
Member

chemzqm commented May 8, 2020

it won't work since grep list can't parse the result,should be possilbe with files source

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants