开发者

Bundler: How to check if Gems are up to date

Using Bundler, is there a way to check if there are newer gems available than the versions specified in the Gemfile? In other words, is there a way to check if my gems are up to date without 开发者_开发问答actually updating?


List installed gems with newer versions available

$ bundle outdated [GEM] [--local] [--pre] [--source]

Options:

--local: Do not attempt to fetch gems remotely and use the gem cache instead

--pre: Check for newer pre-release gems

--source: Check against a specific source

Source: http://bundler.io/v1.3/bundle_outdated.html


If you mean just see if an update is necessary (w/o actually updating), you might have to specify in your Gemfile to use some repo source for comparison, like:

gem "rails", :git => "git://github.com/rails/rails.git"

or specify a specific version to compare against with :version => ...

Then run bundle check and it'll list all gems that are out of date.

EDIT - I guess it depends on what's meant by up to date.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜