简体   繁体   中英

How to install gem in rails 4?

How do you install plugins in Rails 4? Or more specifically, how do you install the Princely plugin for PrinceXML? I've spent a lot of time Googling but have not come up with anything. Everything seems to be for earlier versions of Rails. I get the impression that one would put in in the Gem file somehow? If someone could clarify this for me, I'd be most appreciative.

Gemfile

gem 'princely', '~> 1.4.1'  

or if you prefer to point to github

gem 'princely', github: 'mbleigh/princely'

then run bundle install

Go to into your gemfile, do what Antarr Byrd said. Basically put in those lines above or below and of the lines about gems already there. Running bundle install will result in a new Gemfile.lock, at which point it'll start working.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM