Sha256: 14494df47976901f36ba897440af5b40e66e69a1cbdb4b08d8ee2ed545191aa0
Contents?: true
Size: 1.28 KB
Versions: 1
Compression:
Stored size: 1.28 KB
Contents
gem 'oauth' require 'oauth' gem 'json' require 'json' gem 'haml', '~>2.0.9' require 'haml/util' require 'haml/engine' gem 'chronic' require 'chronic' gem 'curb' require 'curb' require 'logger' gem 'data_objects', '~>0.9.11' gem 'dm-core', '~>0.9.10' gem 'dm-types', '~>0.9.10' gem 'dm-validations', '~>0.9.10' gem 'dm-timestamps', '~>0.9.10' require 'dm-core' require 'dm-types' require 'dm-validations' require 'dm-timestamps' require 'sinatra/base' module <%= name.camelize %> module Log def self.logger if @logger.nil? @logger = Logger.new("<%= name %>.log") @logger.level = Logger::INFO end @logger end end module OAuth def self.consumer ::OAuth::Consumer.new(ENV['<%= name.upcase %>_READKEY'], ENV['<%= name.upcase %>_READSECRET'], {:site => 'http://twitter.com'}) end end def self.retryable(options = {}, &block) opts = { :tries => 1, :on => StandardError }.merge(options) retry_exception, retries = opts[:on], opts[:tries] begin return yield rescue retry_exception retry if (retries -= 1) > 0 end yield end end require File.dirname(__FILE__)+'/<%= name %>/models/user' require File.dirname(__FILE__)+'/<%= name %>/sinatra/app'
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
singem-0.0.2 | lib/generators/twitter/templates/lib/templates.rb.erb |