Vincent Robert
b025dfcf58
Add \r to IFS instead of removing it manually
hace 10 años
Vincent Robert
f50cee2ac7
Simplify bash expression
hace 10 años
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.
hace 10 años
wmoxam
2f5d9a6f90
Fixes rbenv on OpenBSD and any other systems that don't support head -c
hace 10 años
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
hace 11 años
Sam Stephenson
37eca782cc
Documentation tweaks
hace 11 años
Mislav Marohnić
3436bddaea
new-style documentation for most commands
hace 11 años
Mislav Marohnić
21391c8d2f
put up a note why `version-file-read` is tricky
hace 11 años
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
hace 13 años
Sam Stephenson
0632325a43
Set RBENV_DEBUG=1 to see what's going on under the hood
hace 13 años
Sam Stephenson
e5c0fd22e1
Exit with 0 status when a version file is read successfully
hace 13 años
Sam Stephenson
db2a94d4bc
`rbenv-version-name` returns `system` for empty version files. Closes #62 , #65 , #77 .
hace 13 años
Sam Stephenson
837bfc5aa9
Fix rbenv-version-file-read for version files without trailing newlines
hace 13 años
Sam Stephenson
506bc3634f
Extract rbenv-version-file{,-read,-write}
hace 13 años