Sha256: 7357e8cfeb3317d33c1cc5f54762d95d473ea3ece165ad764ed0ad4a706aa509

Contents?: true

Size: 621 Bytes

Versions: 37

Compression:

Stored size: 621 Bytes

Contents

# We're using this strategy borrowed from ActiveSupport to
# make command syntax a little more flexible. In a perfect 
# world we'd just use the double splat feature of Ruby, but 
# support for that is pretty limited at this point, so we're 
# going the extra mile to be cool.
#
module Caracal
  class Utilities
    
    #-------------------------------------------------------------
    # Public Class Methods
    #-------------------------------------------------------------
    
    def self.extract_options!(args)
      if args.last.is_a?(Hash)
        args.pop
      else
        {}
      end
    end
    
  end
end

Version data entries

37 entries across 37 versions & 2 rubygems

Version Path
caracal_the_curve-1.4.6 lib/caracal/utilities.rb
caracal_the_curve-1.4.5 lib/caracal/utilities.rb
caracal_the_curve-1.4.4 lib/caracal/utilities.rb
caracal_the_curve-1.4.3 lib/caracal/utilities.rb
caracal_the_curve-1.4.2 lib/caracal/utilities.rb
caracal_the_curve-1.4.1 lib/caracal/utilities.rb
caracal-1.4.1 lib/caracal/utilities.rb
caracal-1.4.0 lib/caracal/utilities.rb
caracal-1.3.0 lib/caracal/utilities.rb
caracal-1.2.0 lib/caracal/utilities.rb
caracal-1.1.2 lib/caracal/utilities.rb
caracal-1.1.1 lib/caracal/utilities.rb
caracal-1.1.0 lib/caracal/utilities.rb
caracal-1.0.13 lib/caracal/utilities.rb
caracal-1.0.12 lib/caracal/utilities.rb
caracal-1.0.11 lib/caracal/utilities.rb
caracal-1.0.10 lib/caracal/utilities.rb
caracal-1.0.9 lib/caracal/utilities.rb
caracal-1.0.8 lib/caracal/utilities.rb
caracal-1.0.7 lib/caracal/utilities.rb