Changesets can be listed by changeset number.
The Git repository is here.
- Revision:
- 381
- Log:
Radiant is now packaged as a Gem - see Changeset #373, Changeset #374,
Changeset #375, Changeset #376, Changeset #377, Changeset #378,
Changeset #379 and Changeset #380. The application part of Radiant is
now mostly empty; it exists to provide a structure which hooks into the
gem and which provides a framework for extensions. Included in this big
changeset are all the deletions, additions and changes needed to go from
the old ROOL customised Radiant to a new ROOL customised Radiant, which
includes several custom extensions adapted from the old Radiant
modifications and requires Radiant 0.9.1 to be installed as a gem.
- Author:
- rool
- Date:
- Mon Mar 21 14:01:18 +0000 2011
- Size:
- 4594 Bytes
1 | # Be sure to restart your server when you modify this file |
2 | |
3 | # Uncomment below to force Rails into production mode when |
4 | # you don't control web/app server and can't set it the proper way |
5 | # ENV['RAILS_ENV'] ||= 'production' |
6 | |
7 | require File.join(File.dirname(__FILE__), 'boot') |
8 | require 'radius' |
9 | require 'active_support/secure_random' |
10 | |
11 | Radiant::Initializer.run do |config| |
12 | # Skip frameworks you're not going to use (only works if using vendor/rails). |
13 | # To use Rails without a database, you must remove the Active Record framework |
14 | config.frameworks -= [ :action_mailer ] |
15 | |
16 | # Only load the extensions named here, in the order given. By default all |
17 | # extensions in vendor/extensions are loaded, in alphabetical order. :all |
18 | # can be used as a placeholder for all extensions not explicitly named. |
19 | # config.extensions = [ :all ] |
20 | |
21 | # By default, only English translations are loaded. Remove any of these from |
22 | # the list below if you'd like to provide any of the supported languages |
23 | config.extensions -= [:dutch_language_pack, :french_language_pack, :german_language_pack, |
24 | :italian_language_pack, :japanese_language_pack, :russian_language_pack] |
25 | |
26 | # Your secret key for verifying cookie session data integrity. |
27 | # If you change this key, all old sessions will become invalid! |
28 | # Make sure the secret is at least 30 characters and all random, |
29 | # no regular words or you'll be exposed to dictionary attacks. |
30 | # |
31 | # 2011-03-09 (ADH): Auto-generation of Secret value taken from Instiki 0.9.1 |
32 | # Secret session key |
33 | # The secret session key is automatically generated, and stored |
34 | # in a file, for reuse between server restarts. If you want to |
35 | # change the key, just delete the file, and it will be regenerated |
36 | # on the next restart. Doing so will invalitate all existing sessions. |
37 | secret_file = Rails.root.join("secret") |
38 | if File.exist?(secret_file) |
39 | secret = secret_file.read |
40 | else |
41 | secret = ActiveSupport::SecureRandom.hex(64) |
42 | File.open(secret_file, 'w', 0600) { |f| f.write(secret) } |
43 | end |
44 | config.action_controller.session = { |
45 | :key => "_radiantapp_session_id", |
46 | :secret => secret |
47 | } |
48 | |
49 | # Comment out this line if you want to turn off all caching, or |
50 | # add options to modify the behavior. In the majority of deployment |
51 | # scenarios it is desirable to leave Radiant's cache enabled and in |
52 | # the default configuration. |
53 | # |
54 | # Additional options: |
55 | # :use_x_sendfile => true |
56 | # Turns on X-Sendfile support for Apache with mod_xsendfile or lighttpd. |
57 | # :use_x_accel_redirect => '/some/virtual/path' |
58 | # Turns on X-Accel-Redirect support for nginx. You have to provide |
59 | # a path that corresponds to a virtual location in your webserver |
60 | # configuration. |
61 | # :entitystore => "radiant:tmp/cache/entity" |
62 | # Sets the entity store type (preceding the colon) and storage |
63 | # location (following the colon, relative to Rails.root). |
64 | # We recommend you use radiant: since this will enable manual expiration. |
65 | # :metastore => "radiant:tmp/cache/meta" |
66 | # Sets the meta store type and storage location. We recommend you use |
67 | # radiant: since this will enable manual expiration and acceleration headers. |
68 | config.middleware.use ::Radiant::Cache |
69 | |
70 | # Use the database for sessions instead of the cookie-based default, |
71 | # which shouldn't be used to store highly confidential information |
72 | # (create the session table with 'rake db:sessions:create') |
73 | config.action_controller.session_store = :cookie_store |
74 | |
75 | # Activate observers that should always be running |
76 | config.active_record.observers = :user_action_observer |
77 | |
78 | # The internationalization framework can be changed to have another default locale (standard is :en) or more load paths. |
79 | # All files from config/locales/*.rb,yml are added automatically. |
80 | # config.i18n.load_path << Dir[File.join(RAILS_ROOT, 'my', 'locales', '*.{rb,yml}')] |
81 | # config.i18n.default_locale = :'en' |
82 | |
83 | # Make Active Record use UTC-base instead of local time |
84 | config.time_zone = 'UTC' |
85 | |
86 | # Set the default field error proc |
87 | config.action_view.field_error_proc = Proc.new do |html, instance| |
88 | if html !~ /label/ |
89 | %{<span class="error-with-field">#{html} <span class="error">#{[instance.error_message].flatten.first}</span></span>} |
90 | else |
91 | html |
92 | end |
93 | end |
94 | |
95 | config.after_initialize do |
96 | # Add new inflection rules using the following format: |
97 | ActiveSupport::Inflector.inflections do |inflect| |
98 | inflect.uncountable 'config' |
99 | end |
100 | end |
101 | |
102 | config.gem 'will_paginate', :version => '~> 2.3.11', :source => 'http://gemcutter.org' |
103 | end |