[Unmaintained] User-centric watching system for Rails 3 applications.
MIT License
= MakeWatchable
MakeWatchable is an extension for building a user-centric watching system for Rails 3 applications. It currently supports ActiveRecord models.
== Installation
add MakeWatchable to your Gemfile
gem 'make_watchable'
afterwards execute
bundle install
generate the required migration file
rails generate make_watchable
migrate the database
rake db:migrate
== Usage
class Repository < ActiveRecord::Base make_watchable end
class User < ActiveRecord::Base make_watcher end
user.watch!(repository)
user.watch(repository)
user.unwatch!(repository)
user.unwatch(repository)
repository.watchings
watching = repository.watchings.first user = watching.watcher
user.watchings
user.watches?(repository)
repository.watched_by?(user)
== Testing
MakeWatchable uses RSpec for testing and has a rake task for executing the provided specs
rake spec
or simply
rake
Copyright © 2010-2011 Kai Schlamp (http://www.medihack.org), released under the MIT license