From 61260870542118ba5f5aec8e74e79f22c763663d Mon Sep 17 00:00:00 2001 From: bruno bornsztein Date: Fri, 7 Dec 2012 11:59:28 -0600 Subject: [PATCH] update readme --- README.markdown | 48 ++++++++++++++++----------------- lib/community_engine/version.rb | 3 +-- 2 files changed, 25 insertions(+), 26 deletions(-) diff --git a/README.markdown b/README.markdown index 91402500..9871baa3 100644 --- a/README.markdown +++ b/README.markdown @@ -1,4 +1,4 @@ -** Using Rails 2.x? You want the [master branch](https://github.com/bborn/communityengine) +** Using Rails 2.x? You want the [rails2.x branch](https://github.com/bborn/communityengine/tree/rails2.x) CommunityEngine [![Build Status](https://secure.travis-ci.org/bborn/communityengine.png)](http://travis-ci.org/bborn/communityengine) @@ -6,7 +6,7 @@ Information at: [http://www.communityengine.org](http://www.communityengine.org) Requirements: - - RAILS VERSION 3.2 + - RAILS VERSION 3.2.8 Getting CommunityEngine Running -------------------------------- @@ -14,7 +14,7 @@ Getting CommunityEngine Running 1. Copy the following into your `Gemfile`: ``` - gem 'community_engine', :git => 'bborn/communityengine', :branch => 'rails3' + gem 'community_engine' ``` 2. Add a file called `application_config.rb` to your `config` directory. In it put (at least): @@ -34,14 +34,14 @@ Getting CommunityEngine Running 5. Delete the default `views/layouts/application.html.erb` that Rails created for you. Delete `public/index.html` if you haven't already. -6. Start your server! +6. Start your server! $ bin/rails server Optional Configuration ====================== -To override the default configuration, create an `application_config.rb` file in `Rails.root/config` +To override the default configuration, create an `application_config.rb` file in `Rails.root/config` The application configuration defined in this file overrides the one defined in the [CommunityEngine gem](https://github.com/bborn/communityengine/blob/rails3/config/application_config.rb) @@ -67,7 +67,7 @@ Photo Uploading By default CommunityEngine uses the filesystem to store photos. -To use Amazon S3 as the backend for your file uploads,you'll need to add a file called `s3.yml` to the application's root config directory (examples are in `/community_engine/sample_files`). +To use Amazon S3 as the backend for your file uploads,you'll need to add a file called `s3.yml` to the application's root config directory (examples are in `/community_engine/sample_files`). You'll need to change your configuration in your `application_config.rb` to tell CommunityEngine to use s3 as the photo backend. For more, see the Paperclip documentation on S3 storage for uploads: https://github.com/thoughtbot/paperclip/blob/master/lib/paperclip/storage/s3.rb @@ -84,9 +84,9 @@ Once logged in as an admin, you'll be able to toggle other users between moderat Admins and moderators can edit and delete other users posts. -There is a rake task to make an existing user into an admin: +There is a rake task to make an existing user into an admin: - rake community_engine:make_admin email=user@foo.com + rake community_engine:make_admin email=user@foo.com (Pass in the e-mail of the user you'd like to make an admin) @@ -97,10 +97,10 @@ Localization Localization is done via Rails native I18n API. We've added some extensions to String and Symbol to let them respond to the `.l` method. That allows for a look up of the symbol (or a symbolized version of the string). -For complex strings with substitutions, Symbols respond to the `.l` method with a hash passed as an argument, for example: +For complex strings with substitutions, Symbols respond to the `.l` method with a hash passed as an argument, for example: :welcome.l :name => current_user.name - + And in your language file you'd have: welcome: "Welcome %{name}" @@ -111,23 +111,23 @@ To customize the language, or add a new language create a new yaml file in `Rail Spam Control ------------ -Spam sucks. Most likely, you'll need to implement some custom solution to control spam on your site, but CE offers a few tools to help with the basics. +Spam sucks. Most likely, you'll need to implement some custom solution to control spam on your site, but CE offers a few tools to help with the basics. ReCaptcha: to allow non-logged-in commenting and use [ReCaptcha](http://recaptcha.net/) to ensure robots aren't submitting comments to your site, just add the following lines to your `application_config.rb`: :allow_anonymous_commenting => true, :recaptcha_pub_key => YOUR_PUBLIC_KEY, :recaptcha_priv_key => YOUR_PRIVATE_KEY - + You can also require ReCaptcha on signup (to prevent automated signups) by adding this in your `application_config.rb` (you'll still need to add your ReCaptcha keys): :require_captcha_on_signup => true - + Akismet: Unfortunately, bots aren't the only ones submitting spam; humans do it too. [Akismet](http://akismet.com/) is a great collaborative spam filter from the makers of Wordpress, and you can use it to check for spam comments by adding one line to your `application_config.rb`: :akismet_key => YOUR_KEY - - + + Integrating with Your Application & Overriding CE ------------------------------------------------- @@ -135,27 +135,27 @@ To make a controller from your application use CE's layout and inherit CE's help class RecipesController < BaseController - before_filter :login_required - + before_filter :login_required + uses_tiny_mce do {:only => [:show], :options => configatron.default_mce_options} - end - + end + end - + To override or modify a controller, helper, or model from CE, you can use the `require_from_ce` helper method. For example, to override a method in CE's `User` model, create `app/models/user.rb`: class User < ActiveRecordBase require_from_ce('models/user') - + #add a new association has_many :recipes - + #override an existing method def display_name login.capitalize end - + end @@ -174,7 +174,7 @@ Contributors - Thanks! :) - Bryan Kearney - localization - Alex Nesbitt - forgot password bugs - Alejandro Raiczyk - Spanish localization -- [Fritz Thielemann](http://github.com/fritzek) - German localization, il8n +- [Fritz Thielemann](http://github.com/fritzek) - German localization, il8n - [Oleg Ivanov](http://github.com/morhekil) - `acts_as_taggable_on_steroids` - David Fugere - French localization - Barry Paul - routes refactoring diff --git a/lib/community_engine/version.rb b/lib/community_engine/version.rb index e81d4f08..4c37b09b 100644 --- a/lib/community_engine/version.rb +++ b/lib/community_engine/version.rb @@ -3,8 +3,7 @@ module Version MAJOR = 2 MINOR = 0 PATCH = 0 - BUILD = 'beta4' STRING = [MAJOR, MINOR, PATCH, BUILD].compact.join('.') end -end \ No newline at end of file +end