magnumripper/JohnTheRipper — pull request #134 by frank-dittrich (2012-12-17 18:29:43+00:00)
Title: Bash completion: support (src)$ cd ../run; ./john -[tab]

The main completion logic is not touched.
Just some way to support completion when the $PWD at the time
of bash completion differs from $PWD at the time the john binary
will be started.

Preconditions:

The same john binary (or at least one with the same list of
supported options) must have been used earlier to successfully
complete a john option so that the absolute path of the
john binary has been stored in a shell variable $__john_binary.

Possible values for options should not depend on $PWD, that means
completing --option=[tab] will not work correctly for these
options:
--config=
--loopback=
--make-charset=
--pot=
--restore=
--status=
--wordlist=