+ print the location of the debug log to stdout on start
[rbot] / launch_here.rb
1 #!/usr/bin/ruby
2 #
3 # Load rbot from this directory. (No need to install it with setup.rb)
4 #
5
6 SCM_DIR = File.expand_path File.dirname(__FILE__)
7 $0 = File.expand_path $0
8
9 Dir.chdir SCM_DIR
10
11 puts "Running from #{SCM_DIR}"
12
13 $:.unshift File.join(SCM_DIR, 'lib')
14
15 module Irc
16 class Bot
17   module Config
18     @@datadir = File.join SCM_DIR, 'data/rbot'
19     @@coredir = File.join SCM_DIR, 'lib/rbot/core'
20   end
21 end
22 end
23
24 load File.join(SCM_DIR, 'bin/rbot')