Source

chitin / bin / chitin

Full commit
#!/usr/bin/env ruby

# fuck, this isn't my method. i don't know where i got it. please don't hate me!
def follow_link(file)
  file = File.expand_path(file)
  while File.symlink?(file)
    file = File.expand_path(File.readlink(file), File.dirname(file))
  end
  file
end

require File.join(File.dirname(follow_link(__FILE__)), "..", "lib", "chitin")

rc = ARGV[0] || File.expand_path('~/.chitinrc')
FileUtils.touch rc

Chitin::Builtins.class_eval File.read(rc)

SESSION = Chitin::Session.new Chitin::Builtins
SESSION.start