From 075b1842a29666e3fb48557dd39d8fe943f04956 Mon Sep 17 00:00:00 2001 From: "Justin Hornosty (jjrh)" Date: Tue, 5 Dec 2017 12:35:01 -0500 Subject: [PATCH] Option to use RVM for ruby --- Makefile | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/Makefile b/Makefile index 9ff680ead..6eb1c4c85 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,4 @@ +SHELL := /bin/bash --login # You can set these variables from the command line. UGLIFYJS ?= node_modules/.bin/uglifyjs BABEL ?= node_modules/.bin/babel @@ -17,6 +18,15 @@ SPHINXBUILD ?= ./bin/sphinx-build SED ?= sed SPHINXOPTS = + + +# In the case user wishes to use RVM +USE_RVM ?= false +RVM_RUBY_VERSION ?= 2.4.2 +ifeq ($(USE_RVM),true) + RVM_USE = rvm use $(RVM_RUBY_VERSION) +endif + # Internal variables. ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) ./docs/source @@ -103,6 +113,7 @@ stamp-npm: package.json stamp-bundler: Gemfile mkdir -p .bundle + $(RVM_USE) gem install --user bundler --bindir .bundle/bin $(BUNDLE) install --path .bundle --binstubs .bundle/bin touch stamp-bundler