Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
photo gallery rails engine (mountable, rails 3.1)
JavaScript Ruby
Branch: master
Failed to load latest commit information.
app [Image] in mongoid does not need album_id field
config [Image] now properly has a mongoid model
doc [Yard] trimmings
extra_docs [Yard] setup ripped from Dragonfly, thanks markevans/dragonfly
lib Bump version, fix specs failing for FactoryGirl syntax changes
plugins [Plugins] in own directory, cleaned up gemspec
script first real commit - albums controller exists, spec passes.
spec Bump version, fix specs failing for FactoryGirl syntax changes
yard [Yard] setup ripped from Dragonfly, thanks markevans/dragonfly
.gitignore [Git] ignore yard cache
.rbenv-version [rbenv] initialized to 1.9.2-p290
.rspec Started work on the basic_list_view extension to provide a way to vie…
.rvmrc Bump version, fix specs failing for FactoryGirl syntax changes
.simplecov [Coverage] adjusted to work with bundle in .bundle/bundle i.e. with r…
.travis.yml [Travis] task added and travis config updated
.yardopts [Yard] setup ripped from Dragonfly, thanks markevans/dragonfly
Gemfile [Gem] added yard and moved sqlite and jquery to development
History.md [Yard] setup ripped from Dragonfly, thanks markevans/dragonfly
LICENSE [Yard] setup ripped from Dragonfly, thanks markevans/dragonfly
LICENSE.md
MIT-LICENSE Initial base for the
README.md [README] github markdown no likey {} style urls
Rakefile [Rake] the yard
imagine.gemspec [MultiDB] support started, active_record working with framework in pl…

README.md

Imagine

Travis CI Build Status

Imagine is a Rails engine that provides drop-in image gallery support. It is extensible, and aims to be the de facto standard for Rails image galleries. Its a Rails image gallery, that's mountable. Works on rails 3.1 at least :) Should work on 3.x

It's still in active development.

See the links on the right for more info.

Installation

Add this to the Gemfile of your Rails 3.1 project:

gem 'imagine'

Bundle that puppy up:

bundle install

Generate an initializer file with:

rails generate imagine:initializer

Edit it with a sensible editor to taste:

vi config/initializers/imagine.rb

Install the migrations if you use ActiveRecord with:

rails generate imagine:migration

And run the migrations with:

rake db:migrate

Imagine mounting Imagine, then do it!:

mount Imagine::Engine, :at => "/imagine"

Finally, visit /imagine/albums in your browser to get started.

Features

  • Mountable rails engine. Drops in to provide photo album support.
  • Plugin system allows new album view types to be built as minimal rails engines of their own.
  • Set default album style in your app.
  • View any album in any style by passing the plugin in params.
  • Supports ActiveRecord or Mongoid

External Dependencies

Imagine uses Dragonfly, which assumes you have ImageMagick installed on your server.

Plugins

See the documentation.

Testing

I've got this set up to use spork, so just do the following:

In one terminal, do:

bundle exec spork rspec

In another terminal, once that's done, you can:

bundle exec rake spec
RAILS_ENV=test_mongoid bundle exec rake spec

Todo

  • Allow a user to choose the default display style at album level
  • Provide a standard means of wrapping with authentication
  • Provide a happy-path for attaching albums polymorphically to other objects
  • Make it look a little prettier. Provide a stylesheet that you can include if you so desire.

Contributing

If you want to contribute, you can do so a few different ways. You could fork us on github, you could build a new album view plugin, or you could just give us some feedback or suggestions.

Issues/Suggestions/Questions

Please use the github issue tracker.

Credits

License

This project uses MIT-LICENSE.

Copyright

Copyright (c) 2011 Josh Adams. See LICENSE for details.

Something went wrong with that request. Please try again.