Skip to content

Comment on Cool, but obscure Unix toolsparent

Comments

I always install it by downloading standalone version from http://betterthangrep.com/ There is a command on the homepage you can copy paste to shell and execute.

Ack is simply too often used and I don't want to type ack-grep all the time.

  sudo dpkg-divert  --local --divert /usr/bin/ack --rename --add /usr/bin/ack-grep
That way you still get the benefits of the packaging system and you don't have to alias or create a /usr/local/bin symlink.

"man alias" ?

    <nit>
    $ man alias
    No manual entry for alias
    $ man bash

    ALIASES
           Aliases allow a string to be substituted for a word when it is used as the first word of a simple command.
    </nit>
alias is not a standalone, it's part of the shell (in bash at least).

Sometimes there are aliases for bash built-ins that will take you to the manpage. For me, 'man alias' brings up:

  BASH_BUILTINS(1)
Though, I'm using zsh which may be layering something in there.

Try "help alias"

Alias (though not 'man alias' :) ) could work. But I prefer my way (on server) because I have one thing less to worry about, namely putting 'alias ack=ack-grep' to .bash_aliases. Yeah, it's quick and dirty I guess...

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.