- home :: github.com/feedreader/pluto
- bugs :: github.com/feedreader/pluto/issues
- gem :: rubygems.org/gems/pluto-models
- rdoc :: rubydoc.info/gems/pluto-models
- forum :: groups.google.com/group/wwwmake
Site • Feed • Item • Subscription
class Site
has_many :subscriptions
has_many :feeds, :through => :subscriptions
has_many :items, :through => :feeds
...
end
class Feed
has_many :items
has_many :subscriptions
has_many :sites, :through => :subscriptions
...
end
class Item
belongs_to :feed
...
end
class Subscription
belongs_to :site
belongs_to :feed
...
end
DB_CONFIG = {
adapter: 'sqlite3',
database: './planet.db'
}
Pluto.connect( DB_CONFIG )
Pluto::Model::Item.latest.limit(10).each_with_index do |item,i|
puts "[#{i+1}] #{item.title}"
if item.content
puts item.content
elsif item.summary
puts item.summary
else
## warn: no content found
end
end
pluto
- planet generator command line tool using the pluto-models gempluto.live.starter
- sample planet site; sinatra web app starter template in ruby using the pluto-models gempluto.live
- sample planet site; rails web app in ruby using the pluto-models gem
The pluto-models
scripts are dedicated to the public domain.
Use it as you please with no restrictions whatsoever.
Send them along to the wwwmake Forum/Mailing List. Thanks!