Skip to content

Make counsel-ag support limiting in files. - #820

Merged
abo-abo merged 1 commit into
abo-abo:masterfrom
Yevgnen:ag-limit-in-file
Dec 10, 2016
Merged

abo-abo merged 1 commit into
abo-abo:masterfrom
Yevgnen:ag-limit-in-file

Conversation

@Yevgnen

@Yevgnen Yevgnen commented Dec 9, 2016

Copy link
Copy Markdown
Contributor

This is be done by detecting " -- " in extra-ag-args after
prompting, since ag supports " -- pattern file1 file2" style
of searching.

Common usage is: C-u M-x counsel-ag, select a directory, adjust the optional arguments to something like --nocolor --nogroup -- package *.el, and search PATTERN, given results like
screen shot 2016-12-09 at 9 34 37 am

compared to the unlimited file version with argument --nocolor --nogroup

screen shot 2016-12-09 at 9 34 21 am

This is be done by detecting " -- " in extra-ag-args after
prompting, since ag supports " -- pattern file1 file2" style
of searching.
@abo-abo
abo-abo merged commit 0312d5e into abo-abo:master Dec 10, 2016
@abo-abo

abo-abo commented Dec 10, 2016

Copy link
Copy Markdown
Owner

Thanks.

@abo-abo

abo-abo commented Dec 10, 2016

Copy link
Copy Markdown
Owner

With your change, the base-cmd arg is no longer used. Please review.

@Yevgnen

Yevgnen commented Dec 10, 2016

Copy link
Copy Markdown
Contributor Author

Looks like it should be base-cmd on line 1693.

@Yevgnen

Yevgnen commented Dec 10, 2016 •

Copy link
Copy Markdown
Contributor Author

Should I push a rebased commit(--force) or independent fixup in to branch ag-limit-in-file or create a new pull request ? I have no experience of this ...

@abo-abo

abo-abo commented Dec 10, 2016

Copy link
Copy Markdown
Owner

A new PR, I think

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

Successfully merging this pull request may close these issues.

2 participants