Using --no-rdoc and --no-ri with bundler
44,953
Solution 1
Make a file ~/.gemrc
and put this in it:
gem: --no-rdoc --no-ri
That should make it apply whenever you run the gem
command. (Even from bundle install
)
Solution 2
Bundler doesn't include rdoc and ri. There is nothing you need to do.
Solution 3
See https://stackoverflow.com/a/7662245/109618 for a better ~/.gemrc
:
install: --no-rdoc --no-ri
update: --no-rdoc --no-ri
Solution 4
The up-to-date setting for ~/.gemrc
is
gem: --no-document
But as pointed out, this is already bundler
's default.
Author by
deb
Updated on July 15, 2020Comments
-
deb almost 4 years
When using
gem install gem_name
I can pass--no-rdoc
and--no-ri
switches to skip generating RDoc/RI documentation for the gem on install.Is there a similar way to do this with
bundle install
? -
deb over 12 yearsshould it be
gem: --no-rdoc --no-ri
or:gem: --no-rdoc --no-ri
? -
Mitch Dempsey over 12 yearsI copied and pasted what I have in my file, and that has been working for me for a while
-
docwhat over 12 yearsOrder doesn't matter, btw. It's a list of command line flags to pass to gem.
-
Timbinous over 9 yearsSo I see I'm downvoted 5 times. Can anyone explain how I am wrong? Bundler does not include RDoc and RI files when you install gems using
bundle install
. People wanted this as a feature to allow you to install the documentation but they just don't allow it. -
p4sh4 over 9 yearsTimbinous is right. It is not only correct, it should be the accepted answer because it actually answers the question. Damn shame people are herd-downvoting a correct answer when they know nothing.
-
Timbinous about 9 yearsJust so I'm clear Cyril. When he asks is there a similar way to do this with bundle install? Telling him that bundler already does this for you by default is not actually solving his problem. He never had a problem to begin with. I was telling him that.
-
Kris almost 5 yearsWorks with gem 2.x
-
buncis almost 3 yearsthe updated config is
--no-document
ruby-lang.org/en/news/2018/12/25/ruby-2-6-0-released guides.rubygems.org/rubygems-basics -
A moskal escaping from Russia about 2 yearsSince Ruby 2.5 "Merge RubyGems 3.0.1. The --ri and --rdoc options have been removed. Please use the --document and --no-document options instead.". All the other answers are outdated.