<commit_before>== Blame

Automatically userstamps create and update operations if the table has fields named *created_by* and/or *updated_by*.

Blame adds a *userstamps* migration helper which will create both created_by and updated_by columns in your table:

  create_table :widgets do |t|
    t.string :name
    t.timestamps
    t.userstamps
  end

Blame assumes that you are using restful-authentication and defaults to looking for the current user in User.current_user. You
can override this behavior by writing your own *userstamp_object* method in ActiveRecord::Base or any of your models. For example:

  def userstamp_object
    User.find(session[:user_id])
  end

Automatic userstamping can be turned off globally by setting:

  ActiveRecord::Base.record_userstamps = false
  
  
== Installation

  ruby script/plugin install git://github.com/infused/blame.git
  

== Credit

Thanks to <NAME> <<EMAIL>> for writing the original Userstamp plugin
(http://github.com/delynn/userstamp/tree/master), which I've used in many project over the last several years. Unfortunately, its
grown too complex and hard to keep up to date with Rails releases for my tastes. The Blame plugin attempts to mirror the simplicity
of ActiveRecord's timestamp module.

Copyright (c) 2008 <NAME> <<EMAIL>>, released under the MIT license<commit_msg>Create README.rdoc<commit_after>== Blame

Automatically userstamps create and update operations if the table has fields named *created_by* and/or *updated_by*.
The Blame plugin attempts to mirror the simplicity of ActiveRecord's timestamp module.

Blame adds a *userstamps* migration helper which will create both created_by and updated_by columns in your table:

  create_table :widgets do |t|
    t.string :name
    t.timestamps
    t.userstamps
  end

Blame assumes that you are using restful-authentication and defaults to looking for the current user in User.current_user. You
can override this behavior by writing your own *userstamp_object* method in ActiveRecord::Base or any of your models. For example:

  def userstamp_object
    User.find(session[:user_id])
  end

Automatic userstamping can be turned off globally by setting:

  ActiveRecord::Base.record_userstamps = false
  
  
== Installation

  ruby script/plugin install git://github.com/infused/blame.git
  

== Credit

Thanks to <NAME> <<EMAIL>> for writing the original Userstamp plugin
(http://github.com/delynn/userstamp/tree/master), which is the inspiration for this plugin.

Copyright (c) 2008 <NAME> <<EMAIL>>, released under the MIT license
{'fraction_non_alphanumeric': 0.06588235294117648, 'fraction_numerical': 0.003137254901960784, 'mean_word_length': 4.521645021645021, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 15, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3038951', 'n_tokens_mistral': 733, 'n_tokens_neox': 703, 'n_words': 304}