Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Ackr is a very small subset of grep/ack/rak, for very lazy developers.
branch: master
Failed to load latest commit information.
bin Fix bug invalid byte sequence
lib Update dependencies
spec Ignore some directories
.gitignore Initial commit
.rspec Add basic search for string
.travis.yml Remove support of ruby 1.9.2
Gemfile Update rake version to 10.1.0
Gemfile.lock Fix Gemfile.lock
README.markdown Improve README
Rakefile Configure for travis-ci
VERSION Fix Gemfile.lock
ackr.gemspec Update dependencies


Ackr Build Status Gem Version

Ackr is the very minimum subset of grep/ack/rak I can think of for lazy developers.


Grep is a great tool. A very powerful tool. But most of the time, it is too powerful for my needs. I can never remember its syntax nor its options.

Ack is great and powerful too. But here again it has so many options.

As a developer I have really simple needs. As a lazy developer I want the most possible simple tool.

Here comes ackr:

  • Ackr look for a search term into all text files, into all subfolders, from the working directory
  • A search term is either a string (in this case Ackr is case insensitive) or a regexp
  • Ackr has no options
  • Ackr doesn't look into hidden folders/files
  • Search term is displayed in bold font

It runs on unixes. I guess it won't run on windows.

And one more thing: ackr is not a replacement to grep/ack. If you need grep power, just use grep!


gem install ackr


To look for a string (case insensitive):

$ ackr fixme
   8|   # FIXME Separate behaviours: search / print

  21| $ ackr fixme

Using a regexp (same search as above):

$ ackr /fixme/i

If you want to search only in a specific directory, you can temporarily cd into it like this:

(cd your/path && ackr yoursearch)


To look for a string containing spaces, quote the string:

$ ackr 'string with spaces'

To look for a regex containing spaces, quote the regex:

$ ackr '/regex with spaces/'

or escape the spaces:

$ ackr /regex\ with\ spaces/

When your search string contains some characters special to Bash you will have troubles. For example, instead of:

$ ackr &:active

you must use:

$ ackr '&:active'

Ignored files and directories

Ackr doesn't look into hidden files or directories. In addition, ackr ignores the following list of directories:

  • blib
  • CVS
  • _darcs
  • RCS
  • SCCS
  • pkg
  • tmp
  • temp
  • log

If you really want to search into a such directory anyway, simply cd into it and make the search.


Ackr is slow, very slow... May be I will consider performance in a future version.


  • ruby >= 1.9.3


  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature develop)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

There is many other ways to contibute to ackr

  1. Report any bug
  2. Give me ideas
  3. Correct my poor english syntax
  4. Blog about ackr
  5. Tell ackr to your friends and colleagues



Questions and/or Comments

Feel free to email Xavier Nayrac with any questions, or contact me on twitter.

Something went wrong with that request. Please try again.