refinerycms 0.9.6.12 → 0.9.6.13
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +0 -1
- data/Gemfile +2 -3
- data/Rakefile +22 -8
- data/VERSION +1 -1
- data/bin/refinery +2 -2
- data/config/application.rb +5 -6
- data/config/preinitializer.rb +3 -5
- data/db/migrate/20100223211536_remove_themes_table.rb +17 -0
- data/db/schema.rb +1 -12
- data/db/seeds.rb +2 -10
- data/lib/refinery_initializer.rb +14 -10
- data/public/javascripts/refinery/admin.js +20 -13
- data/readme.md +15 -9
- data/test/fixtures/users.yml +16 -0
- data/test/functional/dashboard_controller_test.rb +24 -0
- data/test/test_helper.rb +5 -0
- data/themes/demolicious/LICENSE +21 -0
- data/themes/demolicious/README +1 -0
- data/themes/demolicious/images/footer_background.png +0 -0
- data/themes/demolicious/images/header_background.png +0 -0
- data/themes/demolicious/stylesheets/application.css +94 -0
- data/themes/demolicious/stylesheets/formatting.css +36 -0
- data/themes/demolicious/stylesheets/home.css +8 -0
- data/themes/demolicious/stylesheets/ie6.css +0 -0
- data/themes/demolicious/stylesheets/ie7.css +0 -0
- data/themes/demolicious/views/layouts/application.html.erb +20 -0
- data/themes/demolicious/views/pages/home.html.erb +1 -0
- data/themes/demolicious/views/pages/show.html.erb +1 -0
- data/themes/hemingway/LICENSE +7 -0
- data/themes/hemingway/README +3 -0
- data/themes/hemingway/images/archives.gif +0 -0
- data/themes/hemingway/images/footer_black.gif +0 -0
- data/themes/hemingway/images/kyle-header.jpg +0 -0
- data/themes/hemingway/images/readon_black.gif +0 -0
- data/themes/hemingway/images/search.gif +0 -0
- data/themes/hemingway/images/spinner.gif +0 -0
- data/themes/hemingway/images/trackback_pingback.gif +0 -0
- data/themes/hemingway/stylesheets/application.css +713 -0
- data/themes/hemingway/stylesheets/formatting.css +1 -0
- data/themes/hemingway/stylesheets/home.css +1 -0
- data/themes/hemingway/views/layouts/application.html.erb +55 -0
- data/todo.md +3 -1
- data/vendor/plugins/authentication/app/controllers/users_controller.rb +3 -5
- data/vendor/plugins/dashboard/app/controllers/admin/dashboard_controller.rb +1 -0
- data/vendor/plugins/dashboard/app/helpers/admin/dashboard_helper.rb +1 -1
- data/vendor/plugins/images/app/models/image.rb +2 -2
- data/vendor/plugins/pages/rails/init.rb +1 -1
- data/vendor/plugins/refinery/app/views/shared/_menu_branch.html.erb +1 -1
- data/vendor/plugins/refinery/lib/generators/refinery/templates/views/admin/_singular_name.html.erb +0 -1
- data/vendor/plugins/refinery/lib/refinery.rb +1 -0
- data/vendor/plugins/refinery/lib/refinery/admin_base_controller.rb +4 -3
- data/vendor/plugins/refinery/lib/refinery/application_controller.rb +0 -1
- data/vendor/plugins/refinery/lib/refinery/application_helper.rb +0 -27
- data/vendor/plugins/refinery/lib/refinery/initializer.rb +10 -5
- data/vendor/plugins/refinery_settings/app/views/admin/refinery_settings/_refinery_setting.html.erb +0 -1
- data/vendor/plugins/resources/app/models/resource.rb +2 -2
- data/vendor/plugins/themes/app/helpers/themes_helper.rb +25 -0
- data/vendor/plugins/themes/lib/theme_server.rb +11 -7
- data/vendor/plugins/themes/rails/init.rb +18 -19
- data/vendor/plugins/themes/themes.md +1 -23
- metadata +43 -18
- data/test/fixtures/themes.yml +0 -5
- data/test/unit/theme_test.rb +0 -19
- data/vendor/plugins/themes/app/controllers/admin/themes_controller.rb +0 -25
- data/vendor/plugins/themes/app/models/theme.rb +0 -56
- data/vendor/plugins/themes/app/views/admin/themes/_form.html.erb +0 -11
- data/vendor/plugins/themes/app/views/admin/themes/_theme.html.erb +0 -18
- data/vendor/plugins/themes/app/views/admin/themes/edit.html.erb +0 -1
- data/vendor/plugins/themes/app/views/admin/themes/index.html.erb +0 -34
- data/vendor/plugins/themes/app/views/admin/themes/new.html.erb +0 -1
- data/vendor/plugins/themes/config/routes.rb +0 -12
@@ -0,0 +1 @@
|
|
1
|
+
@import url('/stylesheets/refinery/formatting.css');
|
@@ -0,0 +1 @@
|
|
1
|
+
@import url('/stylesheets/refinery/home.css');
|
@@ -0,0 +1,55 @@
|
|
1
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2
|
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3
|
+
<%= render :partial => "/shared/head", :locals => {:theme => true} %>
|
4
|
+
<body>
|
5
|
+
<div id="header">
|
6
|
+
<div class="inside">
|
7
|
+
<h2>
|
8
|
+
<%= link_to RefinerySetting.find_or_set(:site_name, "Company Name"), root_url %>
|
9
|
+
</h2>
|
10
|
+
<p class="description">
|
11
|
+
<%= link_to "Home", root_url %>
|
12
|
+
</p>
|
13
|
+
</div>
|
14
|
+
</div>
|
15
|
+
<div id='primary'>
|
16
|
+
<div class='inside clearfix'>
|
17
|
+
<%= yield %>
|
18
|
+
</div>
|
19
|
+
</div>
|
20
|
+
<div id="ancillary">
|
21
|
+
<div class="inside">
|
22
|
+
<div class="block first" style='margin: 0;'>
|
23
|
+
<h2>Recent Posts</h2>
|
24
|
+
<% if NewsItem.latest.empty? %>
|
25
|
+
<p>No news posts yet</p>
|
26
|
+
<% else %>
|
27
|
+
<ul>
|
28
|
+
<% NewsItem.latest.each do |item| %>
|
29
|
+
<li>
|
30
|
+
<%= link_to item.title, news_item_url(item) %>
|
31
|
+
</li>
|
32
|
+
<% end %>
|
33
|
+
</ul>
|
34
|
+
<% end %>
|
35
|
+
</div>
|
36
|
+
<div class="block pages">
|
37
|
+
<h2>
|
38
|
+
Pages
|
39
|
+
</h2>
|
40
|
+
<%= render :partial => 'shared/menu' %>
|
41
|
+
<div class="clear"></div>
|
42
|
+
</div>
|
43
|
+
</div>
|
44
|
+
<hr class="hide" />
|
45
|
+
<div id="footer">
|
46
|
+
<div class="inside">
|
47
|
+
<p style='clear: both; text-align: center;'>
|
48
|
+
Copyright © <%= Time.now.year %>
|
49
|
+
<%= RefinerySetting.find_or_set(:site_name, "Company Name") %>
|
50
|
+
</p>
|
51
|
+
</div>
|
52
|
+
</div>
|
53
|
+
</div>
|
54
|
+
</body>
|
55
|
+
</html>
|
data/todo.md
CHANGED
@@ -18,4 +18,6 @@ We need to have support for build in Refinery field types like "image". So I cou
|
|
18
18
|
|
19
19
|
./script/generate refinery staff name:string bio:text mugshot:image
|
20
20
|
|
21
|
-
And it will automatically create a form field that pops open the image picker on the staff form.
|
21
|
+
And it will automatically create a form field that pops open the image picker on the staff form.
|
22
|
+
|
23
|
+
There is now a partial to easily call an image picker.
|
@@ -57,19 +57,17 @@ class UsersController < ApplicationController
|
|
57
57
|
|
58
58
|
def forgot
|
59
59
|
if request.post?
|
60
|
-
user = User.find_by_email(params[:user][:email])
|
61
|
-
|
62
|
-
if user
|
60
|
+
if (user = User.find_by_email(params[:user][:email])).present?
|
63
61
|
user.create_reset_code
|
64
62
|
|
65
63
|
begin
|
66
64
|
flash[:notice] = "An email has been sent to #{user.email} with a link to reset your password."
|
67
65
|
UserMailer.deliver_reset_notification(user, request)
|
68
66
|
rescue
|
69
|
-
info
|
67
|
+
logger.info "Error: email could not be sent for user password reset for user #{user.id} with email #{user.email}"
|
70
68
|
end
|
71
69
|
else
|
72
|
-
flash[:notice] = "Sorry, #{params[:user][:email]} isn't associated with any
|
70
|
+
flash[:notice] = "Sorry, #{params[:user][:email]} isn't associated with any accounts. Are you sure you typed the correct email address?"
|
73
71
|
end
|
74
72
|
|
75
73
|
redirect_back_or_default(forgot_url)
|
@@ -3,7 +3,7 @@ module Admin::DashboardHelper
|
|
3
3
|
def activity_message_for(record)
|
4
4
|
if (activity = Refinery::Plugins.active.find_activity_by_model(record.class)).present? and activity.title.present?
|
5
5
|
title = record.send activity.title
|
6
|
-
link = link_to truncate(title, :length => 45),
|
6
|
+
link = link_to truncate(title.to_s, :length => 45),
|
7
7
|
eval("#{activity.url}(#{activity.nesting("record")}record)"),
|
8
8
|
:title => "See '#{title}'"
|
9
9
|
|
@@ -13,8 +13,8 @@ class Image < ActiveRecord::Base
|
|
13
13
|
|
14
14
|
# we could use validates_as_attachment but it produces 4 odd errors like
|
15
15
|
# "size is not in list". So we basically here enforce the same validation
|
16
|
-
# rules here
|
17
|
-
# This is a known
|
16
|
+
# rules here except display the error messages we want
|
17
|
+
# This is a known problem when using attachment_fu
|
18
18
|
def validate
|
19
19
|
if self.filename.nil?
|
20
20
|
errors.add_to_base("You must choose an image to upload")
|
@@ -2,7 +2,7 @@ Refinery::Plugin.register do |plugin|
|
|
2
2
|
plugin.title = "Pages"
|
3
3
|
plugin.description = "Manage content pages"
|
4
4
|
plugin.version = 1.0
|
5
|
-
plugin.menu_match = /admin\/page(_dialog|
|
5
|
+
plugin.menu_match = /admin\/page(_dialog|_part)?s$/
|
6
6
|
plugin.activity = {
|
7
7
|
:class => Page,
|
8
8
|
:url_prefix => "edit",
|
@@ -11,7 +11,7 @@
|
|
11
11
|
<%
|
12
12
|
unless hide_children or
|
13
13
|
menu_branch.parent_id.present? or
|
14
|
-
(children =
|
14
|
+
(children = menu_branch.children.collect{|c| c if c.in_menu?}.compact).empty?
|
15
15
|
-%>
|
16
16
|
<ul class='clearfix'>
|
17
17
|
<%= render :partial => "/shared/menu_branch",
|
data/vendor/plugins/refinery/lib/generators/refinery/templates/views/admin/_singular_name.html.erb
CHANGED
@@ -7,7 +7,6 @@
|
|
7
7
|
<%%= link_to refinery_icon_tag("application_edit.png"), edit_admin_<%= singular_name %>_path(<%= singular_name %>),
|
8
8
|
:title => 'Edit this <%= $title_name.downcase %>' %>
|
9
9
|
<%%= link_to refinery_icon_tag("delete.png"), admin_<%= singular_name %>_path(<%= singular_name %>),
|
10
|
-
:confirm => 'Are you sure you want to remove this <%= $title_name.downcase %> forever?',
|
11
10
|
:class => "cancel confirm-delete",
|
12
11
|
:title => 'Remove this <%= $title_name.downcase %> forever' %>
|
13
12
|
</span>
|
@@ -11,7 +11,7 @@ class Refinery::AdminBaseController < ApplicationController
|
|
11
11
|
end
|
12
12
|
|
13
13
|
def searching?
|
14
|
-
|
14
|
+
params[:search].present?
|
15
15
|
end
|
16
16
|
|
17
17
|
protected
|
@@ -31,8 +31,9 @@ protected
|
|
31
31
|
|
32
32
|
def restrict_controller
|
33
33
|
if Refinery::Plugins.active.reject {|plugin| params[:controller] !~ Regexp.new(plugin.menu_match) }.empty?
|
34
|
-
flash
|
35
|
-
logger.warn "'#{current_user.login}' tried to access '#{params[:controller]}'"
|
34
|
+
flash[:error] = "You do not have permission to access this feature."
|
35
|
+
logger.warn "'#{current_user.login}' tried to access '#{params[:controller]}' but was rejected."
|
36
|
+
redirect_back_or_default(admin_root_url)
|
36
37
|
end
|
37
38
|
end
|
38
39
|
|
@@ -1,7 +1,6 @@
|
|
1
1
|
class Refinery::ApplicationController < ActionController::Base
|
2
2
|
|
3
3
|
helper_method :home_page?, :local_request?, :just_installed?, :from_dialog?, :admin?
|
4
|
-
|
5
4
|
protect_from_forgery # See ActionController::RequestForgeryProtection
|
6
5
|
|
7
6
|
include Crud # basic create, read, update and delete methods
|
@@ -34,24 +34,6 @@ module Refinery::ApplicationHelper
|
|
34
34
|
end
|
35
35
|
end
|
36
36
|
|
37
|
-
def image_tag(source, options={})
|
38
|
-
theme = (options.delete(:theme) == true)
|
39
|
-
tag = super
|
40
|
-
# inject /theme/ into the image tag src if this is themed.
|
41
|
-
tag.gsub!(/src=[\"|\']/) { |m| "#{m}/theme/" }.gsub!("//", "/") if theme
|
42
|
-
|
43
|
-
tag
|
44
|
-
end
|
45
|
-
|
46
|
-
def javascript_include_tag(*sources)
|
47
|
-
theme = (arguments = sources.dup).extract_options![:theme] == true # don't ruin the current sources object
|
48
|
-
tag = super
|
49
|
-
# inject /theme/ into the javascript include tag src if this is themed.
|
50
|
-
tag.gsub!(/\/javascripts\//, "/theme/javascripts/").gsub!(/theme=(.+?)\ /, '') if theme
|
51
|
-
|
52
|
-
tag
|
53
|
-
end
|
54
|
-
|
55
37
|
def jquery_include_tags(use_caching=RefinerySetting.find_or_set(:use_resource_caching, false))
|
56
38
|
if !local_request? and RefinerySetting.find_or_set(:use_google_ajax_libraries, true)
|
57
39
|
"#{javascript_include_tag("http://www.google.com/jsapi").gsub(".js", "")}
|
@@ -123,15 +105,6 @@ module Refinery::ApplicationHelper
|
|
123
105
|
selected = current_page?(page) or (request.path =~ Regexp.new(page.menu_match) unless page.menu_match.blank?) or (request.path == page.link_url)
|
124
106
|
end
|
125
107
|
|
126
|
-
def stylesheet_link_tag(*sources)
|
127
|
-
theme = (arguments = sources.dup).extract_options![:theme] == true # don't ruin the current sources object
|
128
|
-
tag = super
|
129
|
-
# inject /theme/ into the stylesheet link tag href if this is themed.
|
130
|
-
tag.gsub!(/\/stylesheets\//, "/theme/stylesheets/").gsub!(/theme=(.+?)\ /, '') if theme
|
131
|
-
|
132
|
-
tag
|
133
|
-
end
|
134
|
-
|
135
108
|
def setup
|
136
109
|
logger.warn("*** Refinery::ApplicationHelper::setup has now been deprecated from the Refinery API. ***")
|
137
110
|
end
|
@@ -1,7 +1,11 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
1
|
+
if Refinery.is_a_gem
|
2
|
+
begin
|
3
|
+
# Try to include the rails initializer. If this isn't in a gem, this will fail.
|
4
|
+
require 'initializer'
|
5
|
+
rescue LoadError => load_error
|
6
|
+
# we don't need to do anything.
|
7
|
+
puts "*** RefineryCMS gem load failed, attempting to load traditionally... ***"
|
8
|
+
end
|
5
9
|
end
|
6
10
|
|
7
11
|
module Refinery
|
@@ -21,7 +25,8 @@ module Refinery
|
|
21
25
|
# add plugin lib paths to the $LOAD_PATH so that rake tasks etc. can be run when using a gem for refinery or gems for plugins.
|
22
26
|
search_for = Regexp.new(File.join(%W(\( #{Refinery.root.join("vendor", "plugins")} \)? .+? lib)))
|
23
27
|
paths = plugins.collect{ |plugin| plugin.load_paths }.flatten.reject{|path| path.scan(search_for).empty? or path.include?('/rails-') }
|
24
|
-
paths = paths.reject{ |path| path.include?(Refinery.root.to_s) }
|
28
|
+
paths = paths.reject{ |path| path.include?(Refinery.root.to_s) } unless Refinery.is_a_gem
|
29
|
+
paths.uniq!
|
25
30
|
($refinery_gem_plugin_lib_paths = paths).each do |path|
|
26
31
|
$LOAD_PATH.unshift path
|
27
32
|
end
|
data/vendor/plugins/refinery_settings/app/views/admin/refinery_settings/_refinery_setting.html.erb
CHANGED
@@ -4,7 +4,6 @@
|
|
4
4
|
<%= link_to refinery_icon_tag("application_edit.png"), edit_admin_refinery_setting_path(refinery_setting),
|
5
5
|
:title => 'Edit this setting' %>
|
6
6
|
<%= link_to refinery_icon_tag("delete.png"), admin_refinery_setting_path(refinery_setting),
|
7
|
-
:confirm => 'Are you sure you want to remove this setting forever?',
|
8
7
|
:class => "cancel confirm-delete",
|
9
8
|
:title => 'Remove this setting forever' if refinery_setting.destroyable %>
|
10
9
|
</span>
|
@@ -10,8 +10,8 @@ class Resource < ActiveRecord::Base
|
|
10
10
|
|
11
11
|
# we could use validates_as_attachment but it produces 4 odd errors like
|
12
12
|
# "size is not in list". So we basically here enforce the same validation
|
13
|
-
# rules here
|
14
|
-
# This is a known
|
13
|
+
# rules here except display the error messages we want
|
14
|
+
# This is a known problem when using attachment_fu
|
15
15
|
def validate
|
16
16
|
if self.filename.nil?
|
17
17
|
errors.add_to_base("You must choose a file to upload")
|
@@ -0,0 +1,25 @@
|
|
1
|
+
module ThemesHelper
|
2
|
+
def image_tag(source, options={})
|
3
|
+
theme = (options.delete(:theme) == true)
|
4
|
+
tag = super
|
5
|
+
# inject /theme/ into the image tag src if this is themed.
|
6
|
+
tag.gsub!(/src=[\"|\']/) { |m| "#{m}/theme/" }.gsub!("//", "/") if theme
|
7
|
+
tag.gsub(/theme=(.+?)\ /, '') # we need to remove any addition of theme='false' etc.
|
8
|
+
end
|
9
|
+
|
10
|
+
def javascript_include_tag(*sources)
|
11
|
+
theme = (arguments = sources.dup).extract_options![:theme] == true # don't ruin the current sources object
|
12
|
+
tag = super
|
13
|
+
# inject /theme/ into the javascript include tag src if this is themed.
|
14
|
+
tag.gsub!(/\/javascripts\//, "/theme/javascripts/") if theme
|
15
|
+
tag.gsub(/theme=(.+?)\ /, '') # we need to remove any addition of theme='false' etc.
|
16
|
+
end
|
17
|
+
|
18
|
+
def stylesheet_link_tag(*sources)
|
19
|
+
theme = (arguments = sources.dup).extract_options![:theme] == true # don't ruin the current sources object
|
20
|
+
tag = super
|
21
|
+
# inject /theme/ into the stylesheet link tag href if this is themed.
|
22
|
+
tag.gsub!(/\/stylesheets\//, "/theme/stylesheets/") if theme
|
23
|
+
tag.gsub(/theme=(.+?)\ /, '') # we need to remove any addition of theme='false' etc.
|
24
|
+
end
|
25
|
+
end
|
@@ -9,14 +9,18 @@ class ThemeServer
|
|
9
9
|
end
|
10
10
|
|
11
11
|
def call(env)
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
12
|
+
if env["PATH_INFO"] =~ /^\/theme/
|
13
|
+
env["PATH_INFO"].gsub!(/^\/theme\//, '')
|
14
|
+
if (file_path = (dir=Rails.root.join("themes", RefinerySetting[:theme])).join(env["PATH_INFO"])).exist?
|
15
|
+
etag = Digest::MD5.hexdigest("#{file_path.to_s}#{file_path.mtime}")
|
16
|
+
unless (etag == env["HTTP_IF_NONE_MATCH"])
|
17
|
+
status, headers, body = Rack::File.new(dir).call(env)
|
18
|
+
[status, headers.update({"ETag" => etag}), body]
|
19
|
+
else
|
20
|
+
[304, {"ETag" => etag}, []]
|
21
|
+
end
|
18
22
|
else
|
19
|
-
[
|
23
|
+
[404, {}, []]
|
20
24
|
end
|
21
25
|
else
|
22
26
|
@app.call(env)
|
@@ -1,25 +1,24 @@
|
|
1
|
-
|
2
|
-
plugin.title = "Themes"
|
3
|
-
plugin.description = "Upload and manage themes"
|
4
|
-
plugin.version = 1.0
|
5
|
-
plugin.activity = {
|
6
|
-
:class => Theme,
|
7
|
-
:title => 'title',
|
8
|
-
:url_prefix => 'edit',
|
9
|
-
:created_image => "layout_add.png",
|
10
|
-
:updated_image => "layout_edit.png"
|
11
|
-
}
|
12
|
-
end
|
13
|
-
|
1
|
+
# Set up middleware to serve theme files
|
14
2
|
config.middleware.use "ThemeServer"
|
15
|
-
|
16
|
-
|
3
|
+
|
4
|
+
# Add or remove theme paths to/from Refinery application
|
5
|
+
::Refinery::ApplicationController.module_eval %(
|
6
|
+
before_filter do |controller|
|
7
|
+
controller.view_paths.reject! { |v| v.to_s =~ %r{^themes/} }
|
8
|
+
if (theme = RefinerySetting[:theme]).present?
|
9
|
+
# Set up view path again for the current theme.
|
10
|
+
controller.view_paths.unshift Rails.root.join("themes", theme, "views").to_s
|
11
|
+
end
|
12
|
+
end
|
17
13
|
)
|
18
14
|
|
19
|
-
|
20
|
-
|
21
|
-
controller_path = Rails.root.join("themes",
|
15
|
+
if (theme = RefinerySetting[:theme]).present?
|
16
|
+
# Set up controller paths, which can only be brought in with a server restart, sorry. (But for good reason)
|
17
|
+
controller_path = Rails.root.join("themes", theme, "controllers").to_s
|
22
18
|
|
23
19
|
::ActiveSupport::Dependencies.load_paths.unshift controller_path
|
24
20
|
config.controller_paths.unshift controller_path
|
25
|
-
end
|
21
|
+
end
|
22
|
+
|
23
|
+
# Include theme functions into application helper.
|
24
|
+
Refinery::ApplicationHelper.send :include, ThemesHelper
|
@@ -35,7 +35,6 @@ Let's take the ``mytheme`` example theme shown above. This is how the theme is s
|
|
35
35
|
|- javascripts
|
36
36
|
| |- whatever.js
|
37
37
|
|- LICENSE
|
38
|
-
|- preview.png
|
39
38
|
|- README
|
40
39
|
|- stylesheets/
|
41
40
|
| |- application.css
|
@@ -63,10 +62,6 @@ The ``README`` file is just a description of your theme.
|
|
63
62
|
|
64
63
|
This is exactly the same as how you lay your views out in ``app/views/`` just instead of putting them in ``app/views/`` you put them into ``themes/mytheme/views/``
|
65
64
|
|
66
|
-
### Preview Image
|
67
|
-
|
68
|
-
The ``preview.png`` image is used when selecting the theme in the backend. It must be a png file and is ideally 135 x 135 pixels.
|
69
|
-
|
70
65
|
## How do I make my own Theme?
|
71
66
|
|
72
67
|
Create a folder with the name if your theme inside ``/themes`` e.g. ``/themes/mytheme`` and follow the directory structure outlined in 'The structure of a Theme'.
|
@@ -81,26 +76,9 @@ Set the value of that setting to the name of your themes folder. For example, if
|
|
81
76
|
|
82
77
|
set it to ``my_theme`` and hit save.
|
83
78
|
|
84
|
-
## How do I zip my theme to use it on other sites
|
85
|
-
|
86
|
-
If you want to share a theme and install it on another site you have to zip it first.
|
87
|
-
|
88
|
-
It's important to note you don't zip the theme's directory itself, just the contents.
|
89
|
-
|
90
|
-
If I had a theme sitting in:
|
91
|
-
|
92
|
-
themes/mytheme/[theme files here]
|
93
|
-
|
94
|
-
The zip file would look like this
|
95
|
-
|
96
|
-
mytheme.zip
|
97
|
-
|- [theme files here]
|
98
|
-
|
99
|
-
Read 'How do I install someone else's Theme?' to take that zip file and install the theme.
|
100
|
-
|
101
79
|
## How do I install someone else's Theme?
|
102
80
|
|
103
|
-
|
81
|
+
Just copy their theme directory into your themes folder and Refinery will see it.
|
104
82
|
|
105
83
|
## How can I Convert my Current Views into a Theme?
|
106
84
|
|
metadata
CHANGED
@@ -1,7 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: refinerycms
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
4
|
+
prerelease: false
|
5
|
+
segments:
|
6
|
+
- 0
|
7
|
+
- 9
|
8
|
+
- 6
|
9
|
+
- 13
|
10
|
+
version: 0.9.6.13
|
5
11
|
platform: ruby
|
6
12
|
authors:
|
7
13
|
- Resolve Digital
|
@@ -11,7 +17,7 @@ autorequire:
|
|
11
17
|
bindir: bin
|
12
18
|
cert_chain: []
|
13
19
|
|
14
|
-
date: 2010-02-
|
20
|
+
date: 2010-02-25 00:00:00 +13:00
|
15
21
|
default_executable:
|
16
22
|
dependencies: []
|
17
23
|
|
@@ -64,6 +70,7 @@ files:
|
|
64
70
|
- db/migrate/20100127004649_add_reset_code_to_users.rb
|
65
71
|
- db/migrate/20100202034802_remove_custom_title_image_id_and_image_id_from_pages.rb
|
66
72
|
- db/migrate/20100204011654_change_part_titles_to_titleized_version_for_new_format.rb
|
73
|
+
- db/migrate/20100223211536_remove_themes_table.rb
|
67
74
|
- db/schema.rb
|
68
75
|
- db/seeds.rb
|
69
76
|
- doc/.yardoc/checksums
|
@@ -224,7 +231,8 @@ files:
|
|
224
231
|
- test/fixtures/pages.yml
|
225
232
|
- test/fixtures/refinery_settings.yml
|
226
233
|
- test/fixtures/resources.yml
|
227
|
-
- test/fixtures/
|
234
|
+
- test/fixtures/users.yml
|
235
|
+
- test/functional/dashboard_controller_test.rb
|
228
236
|
- test/performance/browsing_test.rb
|
229
237
|
- test/test_helper.rb
|
230
238
|
- test/unit/image_test.rb
|
@@ -234,9 +242,31 @@ files:
|
|
234
242
|
- test/unit/page_test.rb
|
235
243
|
- test/unit/refinery_setting_test.rb
|
236
244
|
- test/unit/resource_test.rb
|
237
|
-
-
|
238
|
-
- themes/demolicious
|
239
|
-
- themes/
|
245
|
+
- themes/demolicious/LICENSE
|
246
|
+
- themes/demolicious/README
|
247
|
+
- themes/demolicious/images/footer_background.png
|
248
|
+
- themes/demolicious/images/header_background.png
|
249
|
+
- themes/demolicious/stylesheets/application.css
|
250
|
+
- themes/demolicious/stylesheets/formatting.css
|
251
|
+
- themes/demolicious/stylesheets/home.css
|
252
|
+
- themes/demolicious/stylesheets/ie6.css
|
253
|
+
- themes/demolicious/stylesheets/ie7.css
|
254
|
+
- themes/demolicious/views/layouts/application.html.erb
|
255
|
+
- themes/demolicious/views/pages/home.html.erb
|
256
|
+
- themes/demolicious/views/pages/show.html.erb
|
257
|
+
- themes/hemingway/LICENSE
|
258
|
+
- themes/hemingway/README
|
259
|
+
- themes/hemingway/images/archives.gif
|
260
|
+
- themes/hemingway/images/footer_black.gif
|
261
|
+
- themes/hemingway/images/kyle-header.jpg
|
262
|
+
- themes/hemingway/images/readon_black.gif
|
263
|
+
- themes/hemingway/images/search.gif
|
264
|
+
- themes/hemingway/images/spinner.gif
|
265
|
+
- themes/hemingway/images/trackback_pingback.gif
|
266
|
+
- themes/hemingway/stylesheets/application.css
|
267
|
+
- themes/hemingway/stylesheets/formatting.css
|
268
|
+
- themes/hemingway/stylesheets/home.css
|
269
|
+
- themes/hemingway/views/layouts/application.html.erb
|
240
270
|
- todo.md
|
241
271
|
- vendor/cache/aasm-2.1.3.gem
|
242
272
|
- vendor/cache/actionmailer-2.3.5.gem
|
@@ -547,14 +577,7 @@ files:
|
|
547
577
|
- vendor/plugins/resources/config/routes.rb
|
548
578
|
- vendor/plugins/resources/rails/init.rb
|
549
579
|
- vendor/plugins/resources/resources.md
|
550
|
-
- vendor/plugins/themes/app/
|
551
|
-
- vendor/plugins/themes/app/models/theme.rb
|
552
|
-
- vendor/plugins/themes/app/views/admin/themes/_form.html.erb
|
553
|
-
- vendor/plugins/themes/app/views/admin/themes/_theme.html.erb
|
554
|
-
- vendor/plugins/themes/app/views/admin/themes/edit.html.erb
|
555
|
-
- vendor/plugins/themes/app/views/admin/themes/index.html.erb
|
556
|
-
- vendor/plugins/themes/app/views/admin/themes/new.html.erb
|
557
|
-
- vendor/plugins/themes/config/routes.rb
|
580
|
+
- vendor/plugins/themes/app/helpers/themes_helper.rb
|
558
581
|
- vendor/plugins/themes/lib/theme_server.rb
|
559
582
|
- vendor/plugins/themes/rails/init.rb
|
560
583
|
- vendor/plugins/themes/themes.md
|
@@ -572,22 +595,25 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
572
595
|
requirements:
|
573
596
|
- - ">="
|
574
597
|
- !ruby/object:Gem::Version
|
598
|
+
segments:
|
599
|
+
- 0
|
575
600
|
version: "0"
|
576
|
-
version:
|
577
601
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
578
602
|
requirements:
|
579
603
|
- - ">="
|
580
604
|
- !ruby/object:Gem::Version
|
605
|
+
segments:
|
606
|
+
- 0
|
581
607
|
version: "0"
|
582
|
-
version:
|
583
608
|
requirements: []
|
584
609
|
|
585
610
|
rubyforge_project:
|
586
|
-
rubygems_version: 1.3.
|
611
|
+
rubygems_version: 1.3.6
|
587
612
|
signing_key:
|
588
613
|
specification_version: 3
|
589
614
|
summary: A beautiful open source Ruby on Rails content manager for small business.
|
590
615
|
test_files:
|
616
|
+
- test/functional/dashboard_controller_test.rb
|
591
617
|
- test/performance/browsing_test.rb
|
592
618
|
- test/test_helper.rb
|
593
619
|
- test/unit/image_test.rb
|
@@ -597,4 +623,3 @@ test_files:
|
|
597
623
|
- test/unit/page_test.rb
|
598
624
|
- test/unit/refinery_setting_test.rb
|
599
625
|
- test/unit/resource_test.rb
|
600
|
-
- test/unit/theme_test.rb
|