Gemfile - A format for describing gem dependencies for Ruby programs. A Gemfile describes the gem dependencies required to execute associated Ruby code.
Gemfiles are a format for describing what gems are required by a Ruby program in order to successfully run.
So I have a ruby sinatra program that runs on a server and I have a Gem file to ensure all its dependancies are installed. However it calls a python script which has its own python module dependancies. Thus when it deploy to server all the ruby gems…
If I have a series of gems that are needed in multiple groups, can I have groups inherit from a base group?
I know I can do:
gem "example", {:groups=>[:group_1, :group_2]}
Or:
group :group_1, :group_2 do
gem "example"
end
But is there a way to…
Is it possible to run bundle install from a ruby system call?
I'm trying to install gems and run tests for a project under another path...
For example the command is:
"cd /some/other/project && bundle install && gem list && rspec spec"
Ideally I…
I am spinning a docker container(alpine base) from a docker file inside a Jenkins pipeline. The container installs:
ruby-rake and ruby-bundler
and I am able to do bundle with no problem
My working directory in this jenkins pipeline has Gemfile and…
I'm having trouble using an environment variable in my Gemfile.
I'm trying to load a gem from a private Github repository with an API key:
auth = ENV['SECRET_GIT']
gem 'foobar', git: "https://#{auth}:x-oauth-basic@github.com/Foo/Bar.git"
But if I…
When I go with gem list from my app folder, the terminal displays the list of all gems installed on my local machine. I want instead to see the project related gems.
I am trying to upgrade our app from Rails 3.2.22 to Rails 4.2.4 with Ruby 2.2.3.
Here's what I've done so far:
Modified Gemfile to specify rails, "~> 4.2.4"
bundle
bundle update rails
The full transcript is below.
ActiveRecord is not specified in…
I'm working with Elastic Beanstalk and I'm getting this error in my logs-
You have already activated rack 1.6.0, but your Gemfile requires rack 1.6.4. Prepending bundle exec to your command may solve this. (Gem::LoadError)
I've seen all related…
I'm trying to set up a private geminabox server to hold some gems my project is developing. I have the server set up, with passenger nginx running geminabox as a rack app. I am able to bundle install pointing at the server without using SSL.
Since…
I'm using rbenv and I have the follow error when I execute rails s
Your Ruby version is 2.0.0, but your Gemfile specified 2.1.2
I was reading this thread: Mavericks, RBENV, Your Ruby version is 2.0.0, but your Gemfile specified 2.1.1
But the error…
I did rails new awesomeapp then when I go to do rails s, I get an error that json-1.8.1 is missing. But when I do bundle install, it's clearly listed. What am I missing?
Donalds-MacBook-Pro:awesomeapp · rails s
Could not find json-1.8.1 in any of…
Bundler documentation for version 1.5 says that I should specify patchlevel as follows:
ruby '1.9.3', :patchlevel => 448
When I follow the instruction and run bundle install, I get:
The Ruby patchlevel in your Gemfile must be a string
If I do
ruby…
We have a git repository with a custom gem.
To install it Gemfile has a line:
gem 'my-gem', :git => 'git@192.168.1.100:my-gem.git'
After installing the gem, it is not shown in RubyMine`s External Libraries.
How to make the gem be shown in External…
After generating a Gemfile.lock from Gemfile, is there any tool to round-trip back to freeze versions in the Gemfile. I'd rather avoid doing it manually.
Background: It's good practice to freeze minor version on gems, e.g. if Gemfile.lock is 2.4.1,…
a gem intends to support gems a or b as alternatives for a functionality.
In code I check with defined?(A) if I fall back to b that's fine.
But as a gem developer how to specify these dependencies?
1) what do I put in the Gemfile.
group…