Skip to content

Commit

Permalink
Added a rake install task, which combines migrate and update into one…
Browse files Browse the repository at this point in the history
…. Updated README install instructions to use this instead.
  • Loading branch information
nelstrom committed Nov 8, 2008
1 parent b909b55 commit d83cb7d
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 12 deletions.
18 changes: 7 additions & 11 deletions README
Original file line number Diff line number Diff line change
Expand Up @@ -86,25 +86,21 @@ There are a number of interesting benefits gained by this approach:
1. Copy this extension into your existing Radiant project (place it at:
[your project location]/vendor/extensions/sns

2. Incorporate the database migrations into your existing database using:
rake db:migrate:extensions
2. Run the install rake task:
rake radiant:extensions:sns:install
This is equivalent to running `rake radiant:extensions:sns:migrate`
then `rake radiant:extensions:sns:update` consecutively.

Or, if you prefer to be more specific to this extension:
rake radiant:extensions:sns:migrate

3. Copy the needed images into Radiant's /public/images directory using:
rake radiant:extensions:sns:update

4. (Optional) Configure your stylesheet and javascript directories. By default
3. (Optional) Configure your stylesheet and javascript directories. By default
The Styles 'n Scripts serves your stylesheets and javascripts out of the
/css and /js folders respectively. You can change these locations via the
"config" rake task:
rake radiant:extensions:sns:config

5. (Optional) Configure your stylesheet and javascript content (MIME) types.
4. (Optional) Configure your stylesheet and javascript content (MIME) types.
Again, you use the Rake "config" task.

6. (Optional) Set a different location for the cache directory. This is set in
5. (Optional) Set a different location for the cache directory. This is set in
The sns_extension.rb file using TEXT_ASSET_CACHE_DIR


Expand Down
9 changes: 8 additions & 1 deletion lib/tasks/sns_extension_tasks.rake
Original file line number Diff line number Diff line change
@@ -1,7 +1,14 @@
namespace :radiant do
namespace :extensions do
namespace :sns do


desc "Runs migrations for SnS, and copies public assets.
Equivalent to running `rake radiant:extensions:sns:migrate`
then `rake radiant:extensions:sns:update` consecutively."
task :install => [:environment, :migrate, :update] do
puts "The SnS extension has been successfully installed."
end

desc "Runs the migration of the SnS extension"
task :migrate => :environment do
require 'radiant/extension_migrator'
Expand Down

0 comments on commit d83cb7d

Please sign in to comment.