rubygems

Checking on empty gems cache fails using Serverspec for Docker image build testing

故事扮演 提交于 2019-12-24 10:23:03
问题 I'm currently having an issue with testing Docker image builds by means of Serverspec. In a nutshell, what I want to do is ensuring that during the image build the Ruby gems build cache gets cleared explicitly, e.g. by issuing rm -rf /usr/lib/ruby/gems/*/cache/*.gem in the Dockerfile. The Dockerfile skeleton I'm working with looks like this: # Dockerfile FROM alpine:3.7 RUN apk add --no-cache \ dumb-init \ ruby \ && apk add --no-cache --virtual .build-deps \ build-base \ ruby-dev RUN gem

`no such name` when attempting to add ruby gem source

被刻印的时光 ゝ 提交于 2019-12-24 10:08:09
问题 I have an artifactory server that is acting as a gem repository. When I try and change the gem sources, I get error no such name gem source -a https://artifactory.example.com/api/gems/gems Error fetching https://artifactory.example.com/api/gems/gems: no such name (https://artifactory.example.com/api/gems/specs.4.8.gz) If I try and bypass the artifactory virtual repository, and point straight at the local repository I get error gem source -a https://artifactory.example.com/api/gems/gems-local/

Common structure of gem

梦想与她 提交于 2019-12-24 09:15:01
问题 As we all know, the common structure of rubygem assumes presence of lib directory. I noticed, that generally in this directory are two items: gem_name.rb and gem_name/ directory. The gem_name/ directory hold main sources of project. It is heart of application. So, the question is about gem_name.rb file. What does it stand for? 回答1: The reason it's structured like that is if you had files other than gem_name.rb in the lib/ directory (say another_file_name.rb ), you'd be liable to cause

Error with rake db:migrate using tiny_tds and sqlserver adapter

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-24 08:23:12
问题 When I try using rake db:migrate I get this error: LoadError: cannot load such file -- tiny_tds/tiny_tds D:/myrailsapp/config/application.rb:7:in `<top (required)>' D:/myrailsapp/Rakefile:4:in `require_relative' D:/myrailsapp/Rakefile:4:in `<top (required)>' LoadError: 126: The specified module could not be found. - D:/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/tiny_tds-1.1.0-x86-mingw32/lib/tiny_tds/2.2/tiny_tds.so D:/myrailsapp/config/application.rb:7:in `<top (required)>' D:

how to update watir?

淺唱寂寞╮ 提交于 2019-12-24 08:21:19
问题 i am getting error while truing to install watir C:>gem install watir ERROR: http://rubygems.org/ does not appear to be a repository ERROR: Could not find a valid gem 'watir' (>= 0) in any repository C:>gem -v 1.3.7 C:>ruby -v ruby 1.9.1p378 (2010-01-10 revision 26273) [i386-mingw32] 回答1: Try gem sources -a http://gems.github.com and then gem install watir 回答2: One line solution (since I can't vote yet): gem install watir --source http://gems.github.com 回答3: That looks like a proxy problem.

Cannot Install gem ffi - Windows 7 64bit

寵の児 提交于 2019-12-24 07:57:58
问题 I am new to learning Cucumber/Ruby. I have tried to install the gem 'ffi' however when I do so from the console I get the following message: Error installing ffi: The last version of ffi (>= 0) to support your Ruby & RubyGems nstalling it with gem install ffi -v 1.9.18 ffi requires Ruby version < 2.5, >= 2.0. The current ruby version 2.5.0. 回答1: There is an open pull request to update ffi for Ruby 2.5. You will need to wait for this update, roll back to ruby Ruby <= 2.4.x, or try to install

Cannot Install gem ffi - Windows 7 64bit

爱⌒轻易说出口 提交于 2019-12-24 07:57:31
问题 I am new to learning Cucumber/Ruby. I have tried to install the gem 'ffi' however when I do so from the console I get the following message: Error installing ffi: The last version of ffi (>= 0) to support your Ruby & RubyGems nstalling it with gem install ffi -v 1.9.18 ffi requires Ruby version < 2.5, >= 2.0. The current ruby version 2.5.0. 回答1: There is an open pull request to update ffi for Ruby 2.5. You will need to wait for this update, roll back to ruby Ruby <= 2.4.x, or try to install

Rails can't find image_magick gem

夙愿已清 提交于 2019-12-24 07:24:07
问题 I am trying to use image_magick gem to process image uploads, but rails can't locate it. I have installed the gem successfully using: gem install mini_magick-1.2.3.gem --local gem update system gem cleanup and my model has require 'rubygems' require 'mini_magick' However, I still get the error: no such file to load -- mini_magick Can I add something to the environment.rb to point rails to the correct location? Environment information: Windows XP/InstantRails 2.0 ruby 1.8.6 (2007-09-24

Using Closure_tree gem instead of Awesome nested set

给你一囗甜甜゛ 提交于 2019-12-24 06:35:30
问题 Hi I followed the link to set up closure_tag gem. When i tried to use closure_tree syntax in the following way (newStructure.find_or_create_by_path(parent) instead of newStructure.move_to_child_of(parent)) ... got the following error : "Can't mass-assign protected attributes: ancestor, descendant, generations" is this the correct way of using newStructure.find_or_create_by_path(parent) ? def self.import(path) newStructure = FileOrFolder.find(:first, :conditions=>["fullpath = ?", path]) if

Error installing Rubygems on ruby command prompt in Win7

妖精的绣舞 提交于 2019-12-24 05:10:10
问题 I got the below error when trying to install rubygems on Ruby command prompt in Win7 (32bit). Note that I installed Ruby1.9.3 & added devkit (DevKit-tdm-32-4.5.2-20111229-1559-sfx.exe) to Ruby already. Below are all things that I have tried: C:\devkit>ruby dk.rb init [INFO] found RubyInstaller v1.9.3 at C:/Ruby193 Initialization complete! Please review and modify the auto-generated 'config.yml' file to ensure it contains the root directories to all of the installed Rubies you want enhanced by