Skip to content

Commit

Permalink
Directory reorganization
Browse files Browse the repository at this point in the history
More Spree or rather Rails-like look.

(parndt: merged this in and made tests pass again, WIP)
  • Loading branch information
kml authored and parndt committed Dec 14, 2010
1 parent bd621d7 commit 345a50c
Show file tree
Hide file tree
Showing 825 changed files with 271 additions and 1,245 deletions.
34 changes: 17 additions & 17 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ GIT

GIT
remote: git://github.com/parndt/authlogic.git
revision: 66ed79515919fe13016911b10ebe734cf8718dc7
revision: 7e3fbbbdeca7ee3c20b4d8826fc5969c08e59f59
specs:
authlogic (2.1.6)
activesupport
Expand Down Expand Up @@ -43,7 +43,7 @@ GIT

GIT
remote: git://github.com/resolve/refinerycms-generators.git
revision: 7a01b5db9035a0b47c0072da98b63b4668adf890
revision: ebc3f44464a93fe1d32c62c8f9ae2b059781b6e6
specs:
refinerycms-generators (0.9.9)

Expand Down Expand Up @@ -74,7 +74,7 @@ PATH
GEM
remote: http://rubygems.org/
specs:
ZenTest (4.4.1)
ZenTest (4.4.2)
abstract (1.0.0)
actionmailer (3.0.3)
actionpack (= 3.0.3)
Expand Down Expand Up @@ -112,14 +112,14 @@ GEM
ZenTest
babosa (0.2.0)
builder (2.1.2)
celerity (0.8.4)
celerity (0.8.5)
childprocess (0.1.4)
ffi (~> 0.6.3)
configuration (1.2.0)
cucumber (0.9.4)
builder (~> 2.1.2)
cucumber (0.10.0)
builder (>= 2.1.2)
diff-lcs (~> 1.1.2)
gherkin (~> 2.2.9)
gherkin (~> 2.3.2)
json (~> 1.4.6)
term-ansicolor (~> 1.0.5)
cucumber-rails (0.3.2)
Expand All @@ -134,7 +134,7 @@ GEM
rake (>= 0.8.7)
friendly_id (3.1.8)
babosa (~> 0.2.0)
gherkin (2.2.9)
gherkin (2.3.2)
json (~> 1.4.6)
term-ansicolor (~> 1.0.5)
i18n (0.5.0)
Expand Down Expand Up @@ -174,19 +174,19 @@ GEM
thor (~> 0.14.4)
rake (0.8.7)
rdoc (2.5.11)
rspec (2.2.0)
rspec-core (~> 2.2)
rspec-expectations (~> 2.2)
rspec-mocks (~> 2.2)
rspec-core (2.2.1)
rspec-expectations (2.2.0)
rspec (2.3.0)
rspec-core (~> 2.3.0)
rspec-expectations (~> 2.3.0)
rspec-mocks (~> 2.3.0)
rspec-core (2.3.0)
rspec-expectations (2.3.0)
diff-lcs (~> 1.1.2)
rspec-mocks (2.2.0)
rspec-rails (2.2.1)
rspec-mocks (2.3.0)
rspec-rails (2.3.0)
actionpack (~> 3.0)
activesupport (~> 3.0)
railties (~> 3.0)
rspec (~> 2.2.0)
rspec (~> 2.3.0)
ruby-prof (0.9.2)
rubyzip (0.9.4)
selenium-webdriver (0.1.1)
Expand Down
3 changes: 0 additions & 3 deletions app/controllers/application_controller.rb

This file was deleted.

2 changes: 0 additions & 2 deletions app/helpers/application_helper.rb

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion bin/refinerycms
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ require 'fileutils'
require 'optparse'

# Load refinerycms
require Pathname.new(File.expand_path(File.dirname(__FILE__) << "/..")).join('vendor', 'refinerycms', 'refinery.rb')
require Pathname.new(File.expand_path(File.dirname(__FILE__) << "/..")).join('refinery.rb')

module Refinery
class AppGenerator
Expand Down
4 changes: 0 additions & 4 deletions config.ru

This file was deleted.

13 changes: 13 additions & 0 deletions config/application.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,18 @@ class Application < Rails::Application

# Configure sensitive parameters which will be filtered from the log file.
config.filter_parameters += [:password]

# Your secret key for verifying the integrity of signed cookies.
# If you change this key, all old signed cookies will become invalid!
# Make sure the secret is at least 30 characters and all random,
# no regular words or you'll be exposed to dictionary attacks.
config.secret_token = '7eb8a07ed3b9ae6ff772bcfe846887671472193a5bd494fcf1a7e7e5b128e2b9b96dea74091044ce31f0c613b1b258b18483a75c4b05b6d42cec2f7ee2a3022e'

config.session_store :cookie_store, :key => '_RefineryApp_session'

# Use the database for sessions instead of the cookie-based default,
# which shouldn't be used to store highly confidential information
# (create the session table with "rails generate session_migration")
# RefineryApp::Application.config.session_store :active_record_store
end
end
32 changes: 1 addition & 31 deletions config/environments/development.rb
Original file line number Diff line number Diff line change
@@ -1,31 +1 @@
RefineryApp::Application.configure do
# Settings specified here will take precedence over those in config/environment.rb

# In the development environment your application's code is reloaded on
# every request. This slows down response time but is perfect for development
# since you don't have to restart the webserver when you make code changes.
config.cache_classes = false

# Log error messages when you accidentally call methods on nil.
config.whiny_nils = true

# Show full error reports and disable caching
config.consider_all_requests_local = true
config.action_view.debug_rjs = true
config.action_controller.perform_caching = false

# Don't care if the mailer can't send
config.action_mailer.raise_delivery_errors = false

# Set the log level to the most chatty.
config.log_level = :debug

# Print deprecation notices to the Rails logger
config.active_support.deprecation = :log

# Only use best-standards-support built into browsers
config.action_dispatch.best_standards_support = :builtin
end

# Don't handle some exceptions with the 404 page.
Refinery.rescue_not_found = false
require File.expand_path("../../../core/lib/generators/templates/config/environments/development.rb", __FILE__)
60 changes: 1 addition & 59 deletions config/environments/production.rb
Original file line number Diff line number Diff line change
@@ -1,59 +1 @@
RefineryApp::Application.configure do
# Settings specified here will take precedence over those in config/environment.rb

# The production environment is meant for finished, "live" apps.
# Code is not reloaded between requests
config.cache_classes = true

# Full error reports are disabled and caching is turned on
config.consider_all_requests_local = false
config.action_controller.perform_caching = true

# Specifies the header that your server uses for sending files
config.action_dispatch.x_sendfile_header = "X-Sendfile"

# For nginx:
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect'

# If you have no front-end server that supports something like X-Sendfile,
# just comment this out and Rails will serve the files

# See everything in the log (default is :info)
# config.log_level = :debug

# Use a different logger for distributed setups
# config.logger = SyslogLogger.new

# Use a different cache store in production
# config.cache_store = :memory_store

# Disable Rails's static asset server (Rails default)
# In production, Apache or nginx will already do this
# Warning: Refinery CMS has enabled this setting.
# Disabling this will means files in your public directly
# won't override core assets that are served from the plugin public directories.
config.serve_static_assets = true

# Enable serving of images, stylesheets, and javascripts from an asset server
# config.action_controller.asset_host = "http://assets.example.com"

# Disable delivery errors, bad email addresses will be ignored
# config.action_mailer.raise_delivery_errors = false

# Enable threaded mode
# config.threadsafe!

# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
# the I18n.default_locale when a translation can not be found)
config.i18n.fallbacks = true

# Send deprecation notices to registered listeners
config.active_support.deprecation = :notify
end

# When true will use Amazon's Simple Storage Service on your production machine
# instead of the default file system for resources and images
Refinery.s3_backend = !(ENV['S3_KEY'].nil? || ENV['S3_SECRET'].nil?)

# Handle some exceptions with the 404 page.
Refinery.rescue_not_found = true
require File.expand_path("../../../core/lib/generators/templates/config/environments/production.rb", __FILE__)
39 changes: 1 addition & 38 deletions config/environments/test.rb
Original file line number Diff line number Diff line change
@@ -1,38 +1 @@
RefineryApp::Application.configure do
# Settings specified here will take precedence over those in config/environment.rb

# The test environment is used exclusively to run your application's
# test suite. You never need to work with it otherwise. Remember that
# your test database is "scratch space" for the test suite and is wiped
# and recreated between test runs. Don't rely on the data there!
config.cache_classes = true

# Log error messages when you accidentally call methods on nil.
config.whiny_nils = true

# Show full error reports and disable caching
config.consider_all_requests_local = true
config.action_controller.perform_caching = false

# Raise exceptions instead of rendering exception templates
config.action_dispatch.show_exceptions = false

# Disable request forgery protection in test environment
config.action_controller.allow_forgery_protection = false

# Tell Action Mailer not to deliver emails to the real world.
# The :test delivery method accumulates sent emails in the
# ActionMailer::Base.deliveries array.
config.action_mailer.delivery_method = :test

# Use SQL instead of Active Record's schema dumper when creating the test database.
# This is necessary if your schema can't be completely dumped by the schema dumper,
# like if you have constraints or database-specific column types
# config.active_record.schema_format = :sql

# Print deprecation notices to the stderr <-- :log until authlogic calms down.
config.active_support.deprecation = :log
end

# Don't handle some exceptions with the 404 page.
Refinery.rescue_not_found = false
require File.expand_path("../../../core/lib/generators/templates/config/environments/test.rb", __FILE__)
7 changes: 0 additions & 7 deletions config/initializers/secret_token.rb

This file was deleted.

8 changes: 0 additions & 8 deletions config/initializers/session_store.rb

This file was deleted.

58 changes: 0 additions & 58 deletions config/routes.rb

This file was deleted.

6 changes: 6 additions & 0 deletions core/app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Filters added to this controller apply to all controllers in the application.
# Likewise, all the methods added will be available for all controllers.

class ApplicationController < ActionController::Base

end
File renamed without changes.
5 changes: 5 additions & 0 deletions core/app/helpers/application_helper.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Methods added to this helper will be available to all templates in the application.

module ApplicationHelper

end
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion vendor/refinerycms/core/crud.md → core/crud.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The best part about ``crudify`` is that this gives you a smart default and if th

## Where is it located?

``vendor/refinerycms/core/lib/refinery/crud.rb``
``core/lib/refinery/crud.rb``

## How do I use it in my engines?

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
6 changes: 3 additions & 3 deletions vendor/refinerycms/core/engines.md → core/engines.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ See: [The Refinery Engine Generator](http://github.com/resolve/refinerycms-gener

## The Structure of an Engine

Think of a engine in Refinery as a small Rails app. Engines have a structure that is extremely similar to a Rails app. Here's an example of Refinery's pages engine (located in Refinery's ``vendor/refinerycms/pages/`` folder)
Think of a engine in Refinery as a small Rails app. Engines have a structure that is extremely similar to a Rails app. Here's an example of Refinery's pages engine (located in Refinery's ``pages/`` folder)

pages
|- app
Expand Down Expand Up @@ -55,9 +55,9 @@ This bit is important. It's where all the controllers are held to manage pages i

end

This single controller allows us to create, read, update and delete pages in the backend. With a little bit of Refinery magic we utilise the [crudify mixin](http://github.com/resolve/refinerycms/blob/master/vendor/refinerycms/core/crud.md) which gives us all of these regular features out of the box.
This single controller allows us to create, read, update and delete pages in the backend. With a little bit of Refinery magic we utilise the [crudify mixin](http://github.com/resolve/refinerycms/blob/master/core/crud.md) which gives us all of these regular features out of the box.

How crudify works is an entire topic of it's own. Checkout the [crudify documentation](http://github.com/resolve/refinerycms/blob/master/vendor/refinerycms/core/crud.md) to get an insight into how that works.
How crudify works is an entire topic of it's own. Checkout the [crudify documentation](http://github.com/resolve/refinerycms/blob/master/core/crud.md) to get an insight into how that works.

### app/views and app/helpers

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
2 changes: 1 addition & 1 deletion vendor/refinerycms/core/lib/core.rb → core/lib/core.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ class Engine < Rails::Engine
app.config.autoload_paths += [
Rails.root.join("app", "presenters"),
Rails.root.join("vendor", "**", "**", "app", "presenters"),
Refinery.root.join("vendor", "refinerycms", "*", "app", "presenters")
Refinery.root.join("**", "app", "presenters")
].flatten
end

Expand Down
Loading

0 comments on commit 345a50c

Please sign in to comment.