public/de.wigbels.ruby/templates/shellscript.rb

39 lines
724 B
Ruby
Raw Normal View History

2025-02-08 16:53:10 +01:00
#!/usr/bin/env ruby
#
# Author: Norbert Wigbels - foobla.wigbels.de/uber-foobla
#
# Info about...
#------------------------------------------
# Tainted mode 0-4
$SAFE=0
#------------------------------------------
require 'logger'
#------------------------------------------
class FooApp < Logger::Application
def initialize(application_name)
super(application_name) # Name of the application.
end
def run
puts "Filename: "+__FILE__.to_s
puts "Linenumber: "+__LINE__.to_s
#log(WARN, 'warning', 'mymethod' )
#@log.error('my_method2') { 'Error!' }
end
end
#------------------------------------------
status = FooApp.new("FooApp").start
#if status != 0
# puts "Some error occured."
#end