Skip to content

Commit

Permalink
updates to rvm_gem to allow passing build options
Browse files Browse the repository at this point in the history
  • Loading branch information
heffergm committed Oct 26, 2012
1 parent f5764fd commit 8e921f0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/puppet/provider/rvm_gem/gem.rb
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,12 @@ def install(useversion = true)
command << "--no-rdoc" << "--no-ri" << resource[:name]
end

# makefile opts,
# must be last
if resource[:withopts]
command << "--" << resource[:withopts]
end

output = execute(command)
# Apparently some stupid gem versions don't exit non-0 on failure
self.fail "Could not install: #{output.chomp}" if output.include?("ERROR")
Expand Down
4 changes: 4 additions & 0 deletions lib/puppet/type/rvm_gem.rb
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,10 @@ def retrieve
isnamevar
end

newparam(:withopts) do
desc "Install the gem with these makefile opts."
end

newparam(:source) do
desc "If a URL is passed via, then that URL is used as the
remote gem repository; if a source is present but is not a valid URL, it will be
Expand Down

0 comments on commit 8e921f0

Please sign in to comment.