Sha256: 2de9689faac98c9e4b040cf81928ab4ee8e9c98da273e9d092361cc85a4ab8dc
Contents?: true
Size: 1.08 KB
Versions: 2
Compression:
Stored size: 1.08 KB
Contents
require 'bundler' require 'active_support/core_ext/hash' require 'sinatra' Bundler.require :default, settings.environment Eucalypt.set_root __dir__ class ApplicationController < Sinatra::Base # Set server set :server, %w[thin webrick] # Set core application file set :app_file, __FILE__ # Set application root directory set :root, Eucalypt.root # Set public folder for static files set :public_folder, Eucalypt.path('app', 'static') # Allow static files to be served set :static, true ::Static = Eucalypt::Static.new(settings.public_folder, symbolize: true).freeze # Set views directory set :views, Eucalypt.path('app', 'views') # Set default ERB template set :erb, layout: :'layouts/main' # Set Hanami HTML and asset helpers helpers Hanami::Helpers, Hanami::Assets::Helpers end Eucalypt.require 'config', '*.rb' Eucalypt.require 'config', 'initializers', '*.rb' Eucalypt.require 'app', 'helpers', '{application_helper.rb}' Eucalypt.require 'app', 'controllers', 'application_controller.rb' Eucalypt.require 'app', '{models,policies,helpers,controllers}', '*.rb'
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
eucalypt-0.4.1 | lib/eucalypt/core/templates/eucalypt/app.rb |
eucalypt-0.4.0 | lib/eucalypt/core/templates/eucalypt/app.rb |