-
-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
81c45ab
commit 4cd379c
Showing
37 changed files
with
402 additions
and
201 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,27 @@ | ||
class Flutie::StyleguidesController < ApplicationController | ||
module Flutie | ||
|
||
unloadable | ||
class StyleguidesController < ApplicationController | ||
|
||
def show | ||
@styleguides = styleguides | ||
render :layout => "flutie" if params[:flutie] == "true" | ||
end | ||
unloadable | ||
|
||
def show | ||
@styleguides = styleguides | ||
render :layout => "flutie" if params[:flutie] == "true" | ||
end | ||
|
||
private | ||
private | ||
|
||
def styleguides | ||
all_styleguide_partials = ActionController::Base.view_paths.map do |view_path| | ||
styleguide_path = File.join(view_path, 'styleguides') | ||
if File.exists?(styleguide_path) | ||
Dir.glob(styleguide_path + '/_*.*') | ||
else | ||
nil | ||
def styleguides | ||
all_styleguide_partials = ActionController::Base.view_paths.map do |view_path| | ||
styleguide_path = File.join(view_path.to_s, 'styleguides') | ||
if File.exists?(styleguide_path) | ||
Dir.glob(styleguide_path + '/_*.*') | ||
else | ||
nil | ||
end | ||
end | ||
all_styleguide_partials.flatten.compact | ||
end | ||
all_styleguide_partials.flatten.compact | ||
end | ||
|
||
end |
This file was deleted.
Oops, something went wrong.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Rails.application.routes.draw do |map| | ||
|
||
resource :styleguides, :as => :styleguide, :controller => 'flutie/styleguides', :only => [:show] | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,69 +1,11 @@ | ||
--- !ruby/object:Gem::Specification | ||
name: flutie | ||
version: !ruby/object:Gem::Version | ||
version: 0.6.9 | ||
platform: ruby | ||
authors: | ||
- thoughtbot | ||
autorequire: | ||
bindir: bin | ||
cert_chain: [] | ||
|
||
date: 2009-07-24 00:00:00 -04:00 | ||
default_executable: | ||
dependencies: [] | ||
|
||
description: Default application styles | ||
email: support@thoughtbot.com | ||
executables: [] | ||
|
||
extensions: [] | ||
|
||
extra_rdoc_files: [] | ||
|
||
files: | ||
- LICENSE | ||
- Rakefile | ||
- README.textile | ||
- app/controllers | ||
- app/controllers/flutie | ||
- app/controllers/flutie/styleguides_controller.rb | ||
- app/views | ||
- app/views/styleguides | ||
- app/views/styleguides/show.html.erb | ||
- config/flutie_routes.rb | ||
- lib/flutie | ||
- lib/flutie/extensions | ||
- lib/flutie/extensions/routes.rb | ||
- lib/flutier.rb | ||
- rails/init.rb | ||
has_rdoc: true | ||
homepage: http://github.com/thoughtbot/flutie | ||
licenses: [] | ||
|
||
post_install_message: | ||
rdoc_options: [] | ||
|
||
require_paths: | ||
- lib | ||
required_ruby_version: !ruby/object:Gem::Requirement | ||
requirements: | ||
- - ">=" | ||
- !ruby/object:Gem::Version | ||
version: "0" | ||
version: | ||
required_rubygems_version: !ruby/object:Gem::Requirement | ||
requirements: | ||
- - ">=" | ||
- !ruby/object:Gem::Version | ||
version: "0" | ||
version: | ||
requirements: [] | ||
|
||
rubyforge_project: | ||
rubygems_version: 1.3.4 | ||
signing_key: | ||
specification_version: 3 | ||
summary: Default application styles | ||
test_files: [] | ||
|
||
Gem::Specification.new do |s| | ||
s.name = 'flutie' | ||
s.version = '1.0.0' | ||
s.date = %q{2010-04-06} | ||
s.email = 'support@thoughtbot.com' | ||
s.homepage = 'http://github.com/thoughtbot/flutie' | ||
s.summary = 'Flutie adds default stylesheets to web apps' | ||
s.description = 'Flutie is a starting point for personal discovery' | ||
s.files = ["app/controllers", "app/controllers/flutie", "app/controllers/flutie/styleguides_controller.rb", "app/views", "app/views/flutie", "app/views/flutie/styleguides", "app/views/flutie/styleguides/show.erb", "app/views/layouts", "app/views/layouts/flutie.erb", "config/initializers", "config/initializers/expansion.rb", "config/routes.rb", "lib/flutie", "lib/flutie/engine.rb", "lib/flutie.rb", "lib/tasks", "lib/tasks/flutie.rake", "README.textile"] | ||
s.authors = ['Chad Pytel', 'Kevin Burg', 'Matt Jankowski', 'Mike Burns', 'Fred Yates'] | ||
end |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
module Flutie | ||
require 'flutie/engine' if defined?(Rails) | ||
end | ||
|
||
require 'flutie/extensions/routes' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
module Flutie | ||
|
||
class Engine < Rails::Engine | ||
end | ||
|
||
end |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
require 'fileutils' | ||
|
||
def copy_files(source_path, destination_path, directory) | ||
source, destination = File.join(directory, source_path), File.join(Rails.root, destination_path) | ||
FileUtils.mkdir_p(destination, :verbose => true) unless File.exist?(destination) | ||
FileUtils.cp_r(source, destination, :verbose => true) | ||
end | ||
|
||
directory = File.dirname(__FILE__) | ||
|
||
namespace :flutie do | ||
desc 'install flutie stylesheets into public/ directory' | ||
task :install => :environment do | ||
# Copy the flutie stylesheets into rails_root/public/flutie | ||
copy_files("../../public/stylesheets", "/public/flutie", directory) | ||
end | ||
end |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
.bundle | ||
db/*.sqlite3 | ||
log/*.log | ||
tmp/**/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Add your own tasks in files placed in lib/tasks ending in .rake, | ||
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake. | ||
|
||
require File.expand_path('../config/application', __FILE__) | ||
|
||
require 'rake' | ||
require 'rake/testtask' | ||
require 'rake/rdoctask' | ||
|
||
Rails::Application.load_tasks |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
class ApplicationController < ActionController::Base | ||
protect_from_forgery | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
module ApplicationHelper | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# This file is used by Rack-based servers to start the application. | ||
|
||
require ::File.expand_path('../config/environment', __FILE__) | ||
run Dummy::Application |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
require File.expand_path('../boot', __FILE__) | ||
|
||
require 'rails/all' | ||
|
||
# If you have a Gemfile, require the gems listed there, including any gems | ||
# you've limited to :test, :development, or :production. | ||
Bundler.require(:default, Rails.env) if defined?(Bundler) | ||
|
||
require 'flutie' | ||
|
||
module Dummy | ||
class Application < Rails::Application | ||
# Settings in config/environments/* take precedence over those specified here. | ||
# Application configuration should go into files in config/initializers | ||
# -- all .rb files in that directory are automatically loaded. | ||
|
||
# Add additional load paths for your own custom dirs | ||
# config.load_paths += %W( #{config.root}/extras ) | ||
|
||
# Only load the plugins named here, in the order given (default is alphabetical). | ||
# :all can be used as a placeholder for all plugins not explicitly named | ||
# config.plugins = [ :exception_notification, :ssl_requirement, :all ] | ||
|
||
# Activate observers that should always be running | ||
# config.active_record.observers = :cacher, :garbage_collector, :forum_observer | ||
|
||
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone. | ||
# Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC. | ||
# config.time_zone = 'Central Time (US & Canada)' | ||
|
||
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded. | ||
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s] | ||
# config.i18n.default_locale = :de | ||
|
||
# Configure generators values. Many other options are available, be sure to check the documentation. | ||
# config.generators do |g| | ||
# g.orm :active_record | ||
# g.template_engine :erb | ||
# g.test_framework :test_unit, :fixture => true | ||
# end | ||
|
||
# Configure sensitive parameters which will be filtered from the log file. | ||
config.filter_parameters << :password | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# Use locked gems if present. | ||
begin | ||
require File.expand_path('../../.bundle/environment', __FILE__) | ||
|
||
rescue LoadError | ||
# Otherwise, use RubyGems. | ||
require 'rubygems' | ||
|
||
# And set up the gems listed in the Gemfile. | ||
if File.exist?(File.expand_path('../../Gemfile', __FILE__)) | ||
require 'bundler' | ||
Bundler.setup | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# SQLite version 3.x | ||
# gem install sqlite3-ruby (not necessary on OS X Leopard) | ||
development: | ||
adapter: sqlite3 | ||
database: db/development.sqlite3 | ||
pool: 5 | ||
timeout: 5000 | ||
|
||
# Warning: The database defined as "test" will be erased and | ||
# re-generated from your development database when you run "rake". | ||
# Do not set this db to the same as development or production. | ||
test: | ||
adapter: sqlite3 | ||
database: db/test.sqlite3 | ||
pool: 5 | ||
timeout: 5000 | ||
|
||
production: | ||
adapter: sqlite3 | ||
database: db/production.sqlite3 | ||
pool: 5 | ||
timeout: 5000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# Load the rails application | ||
require File.expand_path('../application', __FILE__) | ||
|
||
# Initialize the rails application | ||
Dummy::Application.initialize! |
Oops, something went wrong.