Sha256: e2a60b5a5e120e33456dca4dc138850cf6b39a079f3331a3b0a09ff09c8963d1

Contents?: true

Size: 488 Bytes

Versions: 19

Compression:

Stored size: 488 Bytes

Contents

module Vpsb
  module Resources
    class RubyVersion < BaseAskResource
      res :ruby_version
      question 'What version of ruby you want to install (Default 2.1.2)?'
      default  '2.1.2'

      private

      def validate
        Proc.new do |answer|
          next true if answer.strip.empty?
          parts = answer.split('.')
          next false if parts.length != 3
          next false if (parts[0] + parts[1]).to_i < 18
          true
        end
      end
    end
  end
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
vpsb-1.1.8 lib/vpsb/resources/ruby_version.rb
vpsb-1.1.7 lib/vpsb/resources/ruby_version.rb
vpsb-1.1.6 lib/vpsb/resources/ruby_version.rb
vpsb-1.1.5 lib/vpsb/resources/ruby_version.rb
vpsb-1.1.4 lib/vpsb/resources/ruby_version.rb
vpsb-1.1.3 lib/vpsb/resources/ruby_version.rb
vpsb-1.1.2 lib/vpsb/resources/ruby_version.rb
vpsb-1.1.1 lib/vpsb/resources/ruby_version.rb
vpsb-1.1.0 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.9 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.8 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.7 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.6 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.5 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.4 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.3 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.2 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.1 lib/vpsb/resources/ruby_version.rb
vpsb-1.0.0 lib/vpsb/resources/ruby_version.rb