Commit graph

69 commits

Author SHA1 Message Date
Sam Stephenson
36b2d13baa Allow plugins to run code before and after the installation process 2013-01-29 15:07:06 -06:00
Sam Stephenson
aa4a0287f9 Point people to the readme 2012-12-30 15:29:52 -06:00
Sam Stephenson
b9474ae1db Add summary lines for rbenv install and rbenv uninstall 2012-12-30 15:25:52 -06:00
Sam Stephenson
9e49bc5638 Fix rbenv-help invocation 2012-12-30 15:13:26 -06:00
Sam Stephenson
643ea84b3f Delegate to rbenv-help for usage, if available 2012-12-30 15:10:57 -06:00
Sam Stephenson
4f72a1591b CACHE_PATH -> RUBY_BUILD_CACHE_PATH 2012-11-13 17:34:08 -06:00
Loic Nageleisen
776c6e1d0e Simple, optional tarball cache support
Rationale:

Both in development and in production, some usage patterns of ruby-build
are slowed down by the download phase. In scenarios such as
troubleshooting failing builds or with provisioning situations (chef,
vagrant...) the repeated download is unnerving, bandwidth wasting and
simply against etiquette towards tarball hosters.

It also happens that some source sites happen to be down and in such
cases it is helpful to be able to sideload sources to rbenv.

Behavior:

By default nothing changes.

If the variable CACHE_PATH is set, then ruby-build will use that
directory to store a successful download, and will check before
downloading if the tarball is already there, in which case downloading
is skipped.

The file is first downloaded as before in the tmp subdirectory and only
moved afterwards, thus ensuring consistency.

There is no default cache path and the optional variable is to be set by
hand, ensuring people know what they're doing when using ruby-build.

Additionnally, rbenv-install will helpfully set CACHE_PATH if and only
if a RBENV_ROOT/cache directory exists. Again, the directory has to be
created manually.

The CACHE_PATH variable internally ends with a slash to mutualize
non-cached cases. Still, consistency is ensured whether or not a slash
is provided externally.

Notes:

I'm not quite sure CACHE_PATH is a good name, maybe
RUBY_BUILD_CACHE_PATH is better and less conflicting.
2012-11-07 16:43:15 +01:00
Fabio Rehm
cb2a79f111 Allow hooks to be defined for rbenv-install 2012-08-15 23:49:13 -03:00
Sam Stephenson
681d6b59f2 Simplify shared library function loading 2012-08-15 14:43:44 -05:00
Sam Stephenson
db359ec844 Better option parsing for rbenv-install 2012-08-15 14:02:23 -05:00
Sam Stephenson
2d489e7742 Avoid += for compatibility with older bash versions 2012-05-24 13:51:30 -05:00
Sam Stephenson
997c1d3328 Use ~/.rbenv/sources instead of ~/.rbenv/srcs 2012-05-24 13:29:36 -05:00
James Tucker
8b89e24411 If $RBENV_BUILD_ROOT is set, then always ask ruby-build to build $VERSION under that path. 2012-04-28 15:27:24 -07:00
James Tucker
daa4f246e6 rbenv-install supports a -k/--keep flag that by default builds under $RBENV_ROOT/srcs/$VERSION_NAME. 2012-04-28 15:27:19 -07:00
Joshua Peek
e14662de3a Rehash after install 2011-09-23 09:08:53 -05:00
Sam Stephenson
f47e74aa44 Autocompletion 2011-09-13 13:16:03 -05:00
Sam Stephenson
7b4b51a79e Show usage 2011-09-12 20:38:48 -05:00
Sam Stephenson
a72a81b911 Respect RBENV_ROOT 2011-09-12 20:28:24 -05:00
Joshua Peek
56dfc05233 Add basic rbenv-install script 2011-09-06 22:17:51 -05:00