Vincent Robert
b025dfcf58
Add \r to IFS instead of removing it manually
il y a 10 ans
Vincent Robert
f50cee2ac7
Simplify bash expression
il y a 10 ans
Vincent Robert
2fd3b18d39
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.
il y a 10 ans
wmoxam
2f5d9a6f90
Fixes rbenv on OpenBSD and any other systems that don't support head -c
il y a 10 ans
Mislav Marohnić
681435e0b4
Simplify version-file-read to avoid process substitution
Process substitution seems to be causing problems with some versions of
bash on specific systems.
Fixes #401
il y a 11 ans
Sam Stephenson
37eca782cc
Documentation tweaks
il y a 11 ans
Mislav Marohnić
3436bddaea
new-style documentation for most commands
il y a 11 ans
Mislav Marohnić
21391c8d2f
put up a note why `version-file-read` is tricky
il y a 11 ans
Joshua Peek
149e61a649
Don't exit out of piped loop
Can cause the stdin of cat to close too soon causing:
echo: write error: Broken pipe
Fixes #97
il y a 13 ans
Sam Stephenson
0632325a43
Set RBENV_DEBUG=1 to see what's going on under the hood
il y a 13 ans
Sam Stephenson
e5c0fd22e1
Exit with 0 status when a version file is read successfully
il y a 13 ans
Sam Stephenson
db2a94d4bc
`rbenv-version-name` returns `system` for empty version files. Closes #62 , #65 , #77 .
il y a 13 ans
Sam Stephenson
837bfc5aa9
Fix rbenv-version-file-read for version files without trailing newlines
il y a 13 ans
Sam Stephenson
506bc3634f
Extract rbenv-version-file{,-read,-write}
il y a 13 ans