Use readline for reading git commit messages

This way, you can use the arrow keys, etc. to edit input, and they work,
rather than outputting control sequences.
Only attempt using readline for input in bash shells

ksh does not support readline with read.
zsh supports readline with varedit, but its input cannot be fed with a
pipe, which causes the test suite to hang, waiting on the tty's stdin.
Refactor prompt_cmd() into prompt() to avoid eval

The prompt must be displayed on stderr, or else it will become part of the result,
since stdout is used to pass the result back to the caller of _prompt().
Merge pull request #8 from nilbus/readline

Use readline for reading git commit messages