Changeset 131
- Timestamp:
- 01/24/2007 16:09:40 (22 months ago)
- Location:
- trunk/examples/tippytippytepee
- Files:
-
- 1 added
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
trunk/examples/tippytippytepee/tepee.rb
r129 r131 2 2 require 'sandbox' 3 3 $:.unshift File.dirname(__FILE__) + "/../../lib" 4 %w(open-uri rubygems json redcloth camping camping/session acts_as_versioned hpricot cgi).each { |lib| require lib } 4 %w(open-uri rubygems camping camping/session acts_as_versioned 5 json redcloth hpricot cgi pp yaml ostruct).each { |lib| require lib } 5 6 6 7 Camping.goes :Tepee … … 65 66 Tepee::Box.ref Tepee::Models::Page 66 67 Tepee::Box.ref Web 67 Tepee::Box.import Time68 68 Tepee::Box.import URI::HTTP 69 69 Tepee::Box.import OpenURI::Meta 70 Tepee::Box.import Hpricot 71 Tepee::Box.import HashWithIndifferentAccess 70 %w(CGI Time Hpricot HashWithIndifferentAccess 71 PP JSON YAML OpenStruct Sandbox).each { |klass| Tepee::Box.import Kernel.const_get(klass) } 72 Tepee::Box.load "webdev.rb" 72 73 73 74 module Tepee::Controllers … … 172 173 def _show_error(box) 173 174 if @boxx 174 line_no = (@boxx.to_s.scan(/(\d+)/).flatten[1] || "1").to_i - @line_zero -1175 line_no = (@boxx.to_s.scan(/(\d+)/).flatten[1] || "1").to_i - @line_zero + 1 175 176 b { div.error! @boxx } #.to_s.gsub(/.eval.:\d+:/, '') 176 177 pre.plain do
