Skip to content
This repository has been archived by the owner on Aug 14, 2018. It is now read-only.

[DEPRECATED] Programatically determine whether or not a piece of English text meets common-sense quality standards.

License

Notifications You must be signed in to change notification settings

aarongough/validates_text_content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

validates_text_content
======================

validates_text_content is a Rails plugin that provides an ActiveRecord validation for
determining whether or not a block of English text meets certain quality standards.

It is designed to help ease the moderation load associated with administering a community 
website and aims to provide instant feedback to users who might otherwise have their 
content deleted or edited by a moderator.

Examples
========

Rejects:
    "this comment has absolutely no capitalization."
    "This comment has no type of punctuation"
    "Fdkjd dk dkkjhd kjdhkjd kjdhdhdl alkasla lka alk"
    "THIS COMMENT IS ALL IN UPPERCASE. ME NO WANT!"
    "Thiscommenthasabsolutelynospacesthereisnowaythisisgood."
    "THIS COMMENT is MORE THAN 80% CAPITALS."
    "THIS pERSON hAS tHEIR cAPS-lOCK oN."
    
Accepts:
    "This is a very simple test comment."
    "Supercalifragilisticexpialadocious: a super long word!"
    "How many words can I think of that don't contain an 'e'?"
    
For more examples please see the test cases in 'test/validates_text_content_test.rb'.

Installation
============

    # To install using Git via script/plugin:
    ./script/plugin install git://github.com/aarongough/validates_text_content.git
    
    # To install using SVN via script/plugin:
    ./script/plugin install http://svn.github.com/aarongough/validates_text_content.git
    
    # If your application is not under version control you can still install using a SVN export:
    ./script/plugin install -e http://svn.github.com/aarongough/validates_text_content.git

Usage
=====

class Book < ActiveRecord::Base
  validates_text_content :title, :biography
end


Copyright (c) 2010 Aaron Gough (http://thingsaaronmade.com/), released under the MIT license

About

[DEPRECATED] Programatically determine whether or not a piece of English text meets common-sense quality standards.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages