Skip to content

Commit

Permalink
add as goal for 1.0 use autoload directory
Browse files Browse the repository at this point in the history
  • Loading branch information
kassio committed Mar 12, 2014
1 parent 6014eca commit d97090f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ check out the docs for the Perl script 'ack', for obvious reasons:
Goals for 1.0:

* Improve documentation, list all options and shortcuts
* Use `autoload` directory to define functions, instead of `plugin`.
* Add a help toggle `?`(like NERDTree)
* Add option to open all files from result list
* Respect wildignore

6 comments on commit d97090f

@ches
Copy link
Collaborator

@ches ches commented on d97090f Mar 24, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FWIW @rking offered to share what it took for ag.vim on rking#9.

Re: that issue I'm still kind of bummed by the fork, especially when significant contributions come up for consideration like rking#49 that could largely benefit both tools. I handle fallback to Ack on systems where I might not have ag with a simple:

if executable('ag')
  let g:ackprg = 'ag --nogroup --nocolor --column'
endif

And ag has some filetype support now. Though I guess we won't make @rking happy on the shortness of :Ag 😏 Anyhoo this isn't really the best place for me to share this rant, sorry 😇

@Gaelan
Copy link

@Gaelan Gaelan commented on d97090f Jul 1, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ches :command Ag Ack

@ches
Copy link
Collaborator

@ches ches commented on d97090f Jul 1, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Gaelan Yes, absolutely, plus a few others like :AckFile for completeness 😄

I'd recommend these as a bridge to anyone who may want to migrate (back?) from ag.vim to ack.vim, but it doesn't seem appropriate to actually include them in ack.vim. I guess I might entertain a pull request to define Ag commands as aliases if g:ackprg =~# '^ag\s' but that feels like bloat to me unless ag.vim maintainers wished to merge the projects again. This could have been part of an alternative to forking in the first place…

@aymericbeaumet
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For reference, this allows to alias every Ack commands with the Ag equivalent.

for command in ['Ack', 'AckAdd', 'AckFromSearch', 'LAck', 'LAckAdd', 'AckFile', 'AckHelp', 'LAckHelp', 'AckWindow', 'LAckWindow']
  exe 'command ' . substitute(command, 'Ack', 'Ag', "") . ' ' . command
endfor

@bserem
Copy link

@bserem bserem commented on d97090f Nov 2, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am getting E488: Trailing characters with Vim 8.0.707 and the option for aliasing in the last comment.
Ack commands work fine!

@openjck
Copy link

@openjck openjck commented on d97090f Apr 20, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bserem I've found that this works for me:

for command in ['Ack', 'AckAdd', 'AckFromSearch', 'LAck', 'LAckAdd', 'AckFile', 'AckHelp', 'LAckHelp', 'AckWindow', 'LAckWindow']
  execute 'command! -nargs=* ' . substitute(command, 'Ack', 'Ag', '') . ' ' . command . ' <args>'
endfor

Please sign in to comment.