Guide to ruby

From razwiki
Revision as of 11:35, 5 July 2023 by Razzi (talk | contribs) (Created page with "I don't really use ruby but here's some info because projects I use, use ruby. When I install jekyll I get a warning about the user gem directory not being on path: $ gem i...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

I don't really use ruby but here's some info because projects I use, use ruby.

When I install jekyll I get a warning about the user gem directory not being on path:

$ gem install jekyll --user-install
WARNING:  You don't have /home/razzi/.local/share/gem/ruby/3.1.0/bin in your PATH [...]

So I add it as follows to my ~/.profile:

export ruby_home=$(ruby -e 'puts Gem.user_dir')
export PATH="$PATH:$ruby_home/bin"

https://stackoverflow.com/questions/53979362/you-dont-have-path-in-your-path-gem-executables-will-not-run-while-using