module Ric::Zibaldone
Public Class Methods
gemdir()
click to toggle source
# File lib/ric/zibaldone.rb 6 def self.gemdir 7 File.dirname( File.dirname(__FILE__) + '/../../..' ) # Im in lib/ric/zibaldone.rb 8 end
ric_help()
click to toggle source
# File lib/ric/zibaldone.rb 20 def self.ric_help 21 ret = <<-HTML 22 == Ric (formerly RicLib) == 23 This is Riccardo library (my first gem!). Try the following commands maybe 24 Try some of the following: 25 26 pred 'This is in red' 27 pyellow 'This is yellow instead' 28 29 gemdir: #{ gemdir } 30 HTML 31 puts( ret ) 32 ret 33 end
say_hello()
click to toggle source
# File lib/ric/zibaldone.rb 16 def self.say_hello 17 puts "Ric::Zibaldone.say_hello(): This hello is brought to you by ''#{yellow 'Riccardo Carlesso' rescue 'Riccardo Carlesso (Error with color yellow)'}''" 18 end
version()
click to toggle source
# File lib/ric/zibaldone.rb 10 def self.version 11 # TODO memoize/cache this into @@version 12 ver = File.read( File.expand_path('VERSION' , gemdir() ) ) 13 "(v.#{ver})" # for debug 14 end