Changelog History
-
v1.1.2 Changes
March 25, 2019๐ Fix
rehash
mechanism for versions of bash that complain about clobbering/dev/null
Enforce absolute
RBENV_DIR
to avoid having to unsetCDPATH
rbenv-version-file
: ensure that the version file is a filerbenv init -
: fix output to work without args andset -u
๐
rbenv shell
: better error message when shell integration wasn't enabled๐ Enable freezing rbenv version via
rbenv version-name > .ruby-version
in the shellrbenv-which
: avoid changing PATH unless necessaryrbenv-prefix
: do not silence rbenv-which errors for system version -
v1.1.1 Changes
June 15, 2017- ๐ Fix setting environment variable in fish shell
- Rename
OLD_RBENV_VERSION
toRBENV_*
convention
-
v1.1.0 Changes
November 25, 2016Backwards incompatible:
- โ Remove deprecated
ruby-local-exec
executable - โ Remove support for
.rbenv-version
legacy version file - โ Remove support for
default
,global
legacy global version files
๐ Features:
- โ Add support for
rbenv shell -
style of invocation that restores previous version
Housekeeping:
- Adopt Contributor Covenant 1.4
- Replace
.
withsource
for fish shell - Unset CDPATH if it's set by the user
- ๐ Fix
rbenv <cmd> --help
forsh-*
commands - Expand literal tilde in PATH
- โ Remove deprecated
-
v1.0.0 Changes
December 24, 2015๐ rbenv is a robust tool that follows the UNIX methodology to implement per-project selection of Ruby versions and related runtime environment. The rbenv community maintains an ecosystem of plugins, and rbenv has inspired many other forks for managing environments of different programming languages and other software tools.
rbenv works by:
- Having its
shims/
directory prepended to PATH environment variable; ๐ 2. Reading a.ruby-version
file in the project's directory that specifies the Ruby version to be activated.
โฌ๏ธ How to install/upgrade
โฌ๏ธ The rbenv-installer script automates installation or upgrading rbenv on your system with either Homebrew (if available) or by using git to install to
~/.rbenv
directory.๐ For manual installation instructions and more details, see Installation chapter of rbenv README.
๐ Changes since v0.4.0
๐ฑ Speed ๐
- Speed up rbenv with dynamically loaded
realpath
C extension - ๐ Speed up
rbenv rehash
when there are many Ruby versions with similar sets of executables - ๐ Improve performance of
rbenv-which
for "system" version - Avoid
rbenv-exec
calling out torbenv-version-name
twice
To compile the optional C extension that speeds up rbenv across the board:
# substitute with location where you installed rbenv source:$ cd ~/.rbenv $ src/configure && make -C src
๐ New features ๐
- ๐ New plugin hooks
version-name
andversion-origin
enable plugin authors to hook into version selection logic. rbenv versions --skip-aliases --bare
will only list versions that are not aliases (symlinks) for other versions.- ๐
rbenv version-file <dir>
finds a.ruby-version
file in the target directory or any of its parent directories. - ๐
rbenv init
now recognizes and supports fish shell syntax. ๐ rbenv --debug <command>
is a shortcut for enabling RBENV_DEBUG.
๐ฑ Shell integration ๐
- Fix
rbenv()
shell function in ksh and dash - Ubuntu fix : use
source
instead of.
- Reliably detect user's current shell in
rbenv init
- ๐ Improve detection of completion support for commands
- ๐ Fix detecting completions support on OpenBSD
- Check if completion script is readable
- โ Suppress shell warnings when hashing is disabled by
set +h
rbenv()
shell function preserves multiline output ofsh-*
commands
๐ฑ General enhancements โจ
- ๐
rbenv local
now respects.ruby-version
file in parent directories as well - โ
rbenv versions
now emits a warning when no Ruby versions were found - ๐ Consistently support
rbenv <command> --help
as alternative torbenv help <command>
- ๐ Improve parsing of git revision in
rbenv --version
when rbenv was installed from git - Export PS4 when RBENV_DEBUG is set for more informative debug output
๐ Bug fixes ๐
- ๐ Fix incorrect formatting of
rbenv-help
output under MAWK (Ubuntu) - Prefer
gawk
overawk
if both are available - ๐ Fix resolving symlinks in
rbenv-hooks
- ๐ Fix iterating through paths that have spaces in them
- ๐ Fix
rbenv rehash
when paths have spaces in them - More useful error message when rehash fails on a non-writable directory
- ๐ Make
rbenv-exec
fail for invalid Ruby version - Bail out early if
readlink
is not available - Properly resolve symlinks when listing hook scripts
- ๐ Better error message for
rbenv prefix system
- ๐ Fix reading
.ruby-version
on platforms that don't support process substitution - โ Remove carriage return characters in
.ruby-version
files - ๐ Fixes rbenv on OpenBSD and other systems that don't support
head -c
- Guard against exported
CDPATH
- Ensure that
IFS
is reset to its original value within hook scripts
- Having its
-
v0.4.0 Changes
October 07, 2013๐ New features
- ๐ rbenv now prefers
.ruby-version
files to.rbenv-version
files
for specifying local application-specific versions. The
๐.ruby-version
file has the same format as.rbenv-version
but is
๐ compatible with other Ruby version
managers. - ๐ Deprecated
ruby-local-exec
and moved its functionality into the
๐ standardruby
shim. See the ruby-local-exec wiki
๐ page for
โฌ๏ธ upgrade instructions. - Modified shims to include the full path to rbenv so that they can be
invoked without having rbenv's bin directory in the$PATH
. - ๐ Reworked
rbenv help
so that usage and documentation is stored as a
๐ comment in each subcommand, enabling plugin commands to hook into
the help system. - โ Added support for full completion of the command line, not just the
first argument. - โ Added
rbenv --version
for printing the current version of rbenv. - โ Added
/usr/lib/rbenv/hooks
to the plugin hook search path.
๐ Other changes and bug fixes
- Sped up
rbenv init
by avoiding rbenv reinitialization and by
using a simpler indexing approach. - โก๏ธ Updated installation instructions for Zsh and Ubuntu users.
- ๐ Fixed
rbenv which
andrbenv prefix
with system Ruby versions. - ๐ Changed
rbenv exec
to avoid prepending the system Ruby location to
๐$PATH
to fix issues running system Ruby commands that invoke other
commands. - ๐ Changed
rbenv rehash
to ensure it exits with a 0 status code under
๐ normal operation, and to ensure outdated shims are removed first
when rehashing. - Modified
rbenv rehash
to runhash -r
afterwards, when shell
integration is enabled, to ensure the shell's command cache is
cleared. - โ Removed use of the
+=
operator to support older versions of Bash. - Adjusted non-bare
rbenv versions
output to includesystem
, if
present. - ๐ Improved documentation for installing and uninstalling Ruby
๐ versions. - ๐ Fixed
rbenv versions
not to display a warning if the currently
specified version doesn't exist. - ๐ Fixed an instance of local variable leakage in the
rbenv
shell
function wrapper. - ๐ Changed
rbenv shell
to ensure it exits with a non-zero status on
failure. - ๐ Fixed
rbenv which
to account for path entries with spaces. - ๐ Changed
rbenv init
to accept option arguments in any order.
- ๐ rbenv now prefers
-
v0.3.0 Changes
October 07, 2013- โ Added an
rbenv root
command which prints the value of
0๏ธโฃ$RBENV_ROOT
, or the default root directory if it's unset. - Clarified Zsh installation instructions in the Readme.
- โ Removed some redundant code in
rbenv rehash
. - ๐ Fixed an issue with calling
readlink
for paths with spaces. - ๐ Changed Zsh initialization code to install completion hooks only for
interactive shells. - โ Added preliminary support for ksh.
- ๐
rbenv rehash
creates or removes shims only when necessary instead
of removing and re-creating all shims on each invocation. - ๐ Fixed that
RBENV_DIR
, when specified, would be incorrectly
expanded to its parent directory. - โ Removed the deprecated
set-default
andset-local
commands. - โ Added a
--no-rehash
option torbenv init
for skipping the
automatic rehash when opening a new shell.
- โ Added an
-
v0.2.1 Changes
October 07, 2013- ๐ Changed the
rbenv
command to ensure thatRBENV_DIR
is always an
๐ absolute path. This fixes an issue where Ruby scripts using the
๐ruby-local-exec
wrapper would go into an infinite loop when
๐ป invoked with a relative path from the command line.
- ๐ Changed the
-
v0.2.0 Changes
October 07, 2013- 0๏ธโฃ Renamed
rbenv set-default
torbenv global
andrbenv set-local
๐ torbenv local
. Theset-
commands are deprecated and will be
โ removed in the next major release. - rbenv now uses
greadlink
on Solaris. - โ Added a
ruby-local-exec
command which can be used in shebangs in
๐ place of#!/usr/bin/env ruby
to properly set the project-specific
๐ Ruby version regardless of current working directory. - ๐ Fixed an issue with
rbenv rehash
when no binaries are present. - โ Added support for
rbenv-sh-*
commands, which run inside the
current shell instead of in a child process. - โ Added an
rbenv shell
command for conveniently setting the
$RBENV_VERSION
environment variable. - โ Added support for storing rbenv versions and shims in directories
other than~/.rbenv
with the$RBENV_ROOT
environment variable. - โ Added support for debugging rbenv via
set -x
when the
$RBENV_DEBUG
environment variable is set. - ๐จ Refactored the autocompletion system so that completions are now
built-in to each command and shared between bash and Zsh. - โ Added support for plugin bundles in
~/.rbenv/plugins
as documented
in #102. - โ Added
/usr/local/etc/rbenv.d
to the list of directories searched
for rbenv hooks. - โ Added support for an
$RBENV_DIR
environment variable which
0๏ธโฃ defaults to the current working directory for specifying where rbenv
searches for local version files.
- 0๏ธโฃ Renamed
-
v0.1.2 Changes
October 07, 2013- ๐ Fixed rbenv to be more resilient against nonexistent entries in
$PATH
. - Made the
rbenv rehash
command operate atomically. - Modified the
rbenv init
script to automatically runrbenv rehash
so that shims are recreated whenever a new shell is opened. - โ Added initial support for Zsh autocompletion.
- โ Removed the dependency on egrep for reading version files.
- ๐ Fixed rbenv to be more resilient against nonexistent entries in
-
v0.1.1 Changes
October 07, 2013- ๐ Fixed a syntax error in the
rbenv help
command. - โ Removed
-e
from the shebang in favor ofset -e
at the top of
each file for compatibility with operating systems that do not
๐ support more than one argument in the shebang.
- ๐ Fixed a syntax error in the