How do I install Ruby Gems and also cache them along the way?

When using Python with pip, we can specify an environment variable that says it also downloads packages to the cache location: " How do I install from the local cache using pip? "

export PIP_DOWNLOAD_CACHE=$HOME/.pip_download_cache
pip install numpy

      

How can we do the same for bundler?

+3


source to share


1 answer


The command line tool gem

automatically caches gems. From the documentation :



Gem :: Installer does the job of putting files in all the right places on the filesystem, including unpacking the gem into its gem dir, setting the gemspec to the dir directory, storing the cached gem in the dir cache , and installing either wrappers or symbolic links for the executables files.

+3


source







All Articles