Sha256: 4ba30a3cc978eeb53db6ccd93ee9df1dd77b571055781dafc6848cda50d1187b

Contents?: true

Size: 1.24 KB

Versions: 30

Compression:

Stored size: 1.24 KB

Contents

#!/usr/bin/env ruby -wKU

  ############################################################
	# $Id: script.rb 5267 2010-11-22 14:43:50Z rcarlesso $
  ############################################################
  # @author     Riccardo Carlesso
  # @email      riccardo.carlesso@heanet.ie
  # @tags       development, test, REMOVEME
  # @maturity   development
  # @language   Ruby
  ############################################################

# When this works, just remove it!
#require 'ric'
$ver = '1.2.1'

def richiedi(str)
  avail = `gem list #{str}`.split("\n").select{|line| line.match( /#{str} /) }.join('')
  ret =  "Requiring: require '#{str}' [#{avail}].. "
  ret += require( str.to_s ).to_s
  ret 
end

def n
  $count ||= -1
  $count += 1
end

def nputs(s)
  puts "#{n} #{Time.now}: #{s}"
end

def main()
  begin
    nputs "RicLib Test v#{$ver} (you should see something green): '#{ $0 }'"
    nputs "#{richiedi(:rubygems)}"
    nputs "#{richiedi(:ric)}"
    Ric.say_hello
    nputs Ric.version
    nputs "Now invoking: #{white 'Ric.ric_help' }"
    Ric.ric_help #rescue "ERRORS on inviking: Ric.help()"
    nputs "If you seen green, then everything is #{ green('fine') rescue "some ERROR: #{$!}"}"
  rescue
    puts "E. Some exception: #{$!}"
  end
end

main

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
ric-0.14.2 bin/riclib-test
ric-0.14.1 bin/riclib-test
ric-0.14.0 bin/riclib-test
ric-0.13.0 bin/riclib-test
ric-0.12.2 bin/riclib-test
ric-0.12.0 bin/riclib-test
ric-0.11.19 bin/riclib-test
ric-0.11.18 bin/riclib-test
ric-0.11.16 bin/riclib-test
ric-0.11.15 bin/riclib-test
ric-0.11.14 bin/riclib-test
ric-0.11.13 bin/riclib-test
ric-0.11.12 bin/riclib-test
ric-0.11.11 bin/riclib-test
ric-0.11.10 bin/riclib-test
ric-0.11.9 bin/riclib-test
ric-0.11.7 bin/riclib-test
ric-0.11.6 bin/riclib-test
ric-0.11.4 bin/riclib-test
ric-0.11.3 bin/riclib-test