Sha256: bc4a24e9c95df26d35c803448d50bb31e0342052280aaaf90a8124cf0b53a6eb

Contents?: true

Size: 1.16 KB

Versions: 27

Compression:

Stored size: 1.16 KB

Contents

require 'rbbt'
require 'rbbt/resource'

load Rbbt.etc['app.d/init.rb'].find

$class_name = class_name = File.basename(FileUtils.pwd)

$app = app = eval "class #{class_name} < Sinatra::Base; self end"

$LOAD_PATH.unshift('lib')

#{{{ PRE
Log.info{"Loading: " << Rbbt.etc['app.d/pre.rb'].find if Rbbt.etc['app.d/pre.rb'].exists?}
load Rbbt.etc['app.d/pre.rb'].find if Rbbt.etc['app.d/pre.rb'].exists?

#{{{ BASE
app.class_eval do
  Log.info{"Loading: " << Rbbt.etc['app.d/base.rb'].find}
  eval Rbbt.etc['app.d/base.rb'].read, nil, Rbbt.etc['app.d/base.rb'].find
end

#{{{ RESOURCES
Log.info{"Loading: " << Rbbt.etc['app.d/resources.rb'].find}
load Rbbt.etc['app.d/resources.rb'].find

#{{{ ENTITIES
Log.info{"Loading: " << Rbbt.etc['app.d/entities.rb'].find}
load Rbbt.etc['app.d/entities.rb'].find

#{{{ FINDER
app.class_eval do
  Log.info{"Loading: " << Rbbt.etc['app.d/finder.rb'].find}
  eval Rbbt.etc['app.d/finder.rb'].read
end

#{{{ POST
Log.info{"Loading: " << Rbbt.etc['app.d/post.rb'].find if Rbbt.etc['app.d/post.rb'].exists?}
load Rbbt.etc['app.d/post.rb'].find if Rbbt.etc['app.d/post.rb'].exists?

#{{{ RUN
$title = class_name
require 'rack'
use Rack::Deflater
run app

Version data entries

27 entries across 27 versions & 1 rubygems

Version Path
rbbt-util-5.5.59 share/config.ru
rbbt-util-5.5.58 share/config.ru
rbbt-util-5.5.57 share/config.ru
rbbt-util-5.5.56 share/config.ru
rbbt-util-5.5.55 share/config.ru
rbbt-util-5.5.54 share/config.ru
rbbt-util-5.5.53 share/config.ru
rbbt-util-5.5.52 share/config.ru
rbbt-util-5.5.51 share/config.ru
rbbt-util-5.5.50 share/config.ru
rbbt-util-5.5.49 share/config.ru
rbbt-util-5.5.48 share/config.ru
rbbt-util-5.5.47 share/config.ru
rbbt-util-5.5.46 share/config.ru
rbbt-util-5.5.45 share/config.ru
rbbt-util-5.5.44 share/config.ru
rbbt-util-5.5.43 share/config.ru
rbbt-util-5.5.42 share/config.ru
rbbt-util-5.5.41 share/config.ru
rbbt-util-5.5.40 share/config.ru