ignore cache directory used by ruby-build
Improve `rbenv init` instructions for fish

Fish user config file `~/.config/fish/config.fish` loads for every
instance of fish shell, not just interactive ones. Since it's
unnecessary and dangerous to eval `rbenv init -` output in
non-interactive shells, wrap the invocation in a conditional that checks
if the current shell is interactive.

Fixes #501
Remove Neckbeard reference in favor of Advanced
Change 'Advanced Configuration' reference to 'How rbenv hooks into your shell'
Merge pull request #504 from jonathandean/master

Remove Neckbeard reference in favor of Advanced
Merge pull request #491 from peterhoeg/master

ignore cache directory used by ruby-build
Fix test suite when no system Ruby exists

Some tests assumed that the `ruby` executable will be found in system PATH.

Fixes #512, closes #514
Force TAP output from Bats on CI

In Travis CI environment, Bats thinks it's outputting to an interactive
terminal, so it switches to "pretty" format and ANSI escape codes which
don't look well in the final output.
Fixes rbenv on OpenBSD and any other systems that don't support head -c
Merge pull request #521 from wmoxam/master

Fix rbenv on OpenBSD

Fixes #519
Fix test suite running on OpenBSD

The error was "bash: no such file or directory" and it was due to bash
being located in `/usr/local/bin` on OpenBSD 5.4 instead of `/bin` like
on other systems.

Fixed by keeping `/usr/local/bin` in PATH during the test run.
Fix emulating the scenario where system Ruby is missing on OpenBSD

On other systems, we expected to find system Ruby in `/usr/bin`, but in
OpenBSD 5.4 it will be found in `/usr/local/bin`.

This replaces the limited USRBIN_ALT hack with a more generic
`path_without` function that will ensure that the given executable is
not present in the resulting PATH even if it's found in multiple
system paths.
Fix detecting completions support on OpenBSD

The non-extended regex pattern didn't work on OpenBSD so this switches
grep to extended pattern mode that seems to work consistenty on all
systems.
Fix detecting parent shell on OpenBSD and Cygwin

It seems that "comm" header can't be relied on cross-platform, but that
"ucomm" is more portable. I have no idea whether it's the right value to
use here, but it seems to be doing the job.

Also strip trailing whitespace because OpenBSD 5.4 `ps` output is padded
with spaces for some reason.

Fixes #489
Merge branch 'openbsd'

Closes #524
Remove carriage return characters in version file

When created on Windows, .rbenv-version or .ruby-version files may have CR characters that will prevent rbenv from correctly parsing the Ruby version. Discard those characters when reading the file.
Add test for carriage return in ruby-version file
Simplify bash expression
Move carriage return test to version-file-read
Add \r to IFS instead of removing it manually