DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Snippets has posted 5883 posts at DZone. View Full User Profile

Ultimate Radiant CMS Script

  • submit to reddit
        This is a script that builds a <a href="">Radiant CMS</a> site with several third-party extensions I use a lot. This just saves me time from having to look up the setup commands each time. YMMV

I call this power_radiant and stick it in /usr/local/bin.

Update: this has been fixed to work with latest Radiant code (since svn path as changed and freeze:edge task no longer works). You will need Git to be installed on your machine for this to work.

radiant --database sqlite3 $1
cd $1
echo "
  adapter: sqlite3
  database: db/production.sqlite3
  adapter: sqlite3
  database: db/test.sqlite3
" > config/database.yml
svn export vendor/extensions/shards
svn export svn:// vendor/extensions/wym_editor_filter
svn export vendor/extensions/page_attachments
#rake radiant:freeze:edge # stopped working in latest gem
git clone git:// /tmp/radiant
cp -r /tmp/radiant/radiant vendor/radiant
rake production db:bootstrap
rake production db:migrate:extensions
rake production radiant:extensions:wym_editor_filter:install
rake production radiant:extensions:page_attachments:update

To run: 
power_radiant my_site


Snippets Manager replied on Wed, 2007/04/04 - 11:45am

i've been wanting to do this for a long time, but didn't know how. Thanks! also nice to see you use my wym filter! :)