Code Monkey home page Code Monkey logo

paperclip_demo's Introduction

Paperclip Demo

Reference Application

Paperclip Demo Application

Application allows users to manage a list of “friends” using a basic Rails scaffold. Each friend will have a Name and Avatar. Paperclip will provide the image upload and resizing functionality. The app will demonstrate how to create different sized thumbnails, display resized images on different screens, and gracefully degrade to display missing avatars “missing.png” for friends without an avatar.

Install Codebase

Clone the git repository

$ git clone [email protected]:thoughtbot/paperclip_demo.git
$ cd paperclip_demo
$ bundle

Create database and run migrations

$ rake db:create db:migrate

Run the rails server

$ rails s

View Application

From a web browser access the site via localhost:3000

Deploy the application to Heroku

Create an application container on Heroku

$ heroku create

Push the code to the Heroku container

$ git push heroku master

Run any database migrations

$ heroku rake db:migrate

Set the AWS S3 config vars

$ heroku config:add AWS_BUCKET=your_bucket_name
$ heroku config:add AWS_ACCESS_KEY_ID=your_access_key_id
$ heroku config:add AWS_SECRET_ACCESS_KEY=your_secret_access_key

Now view your Heroku application

$ heroku open

Test suite

RSpec and Capybara used for Integration and Unit tests

$ rspec

Credits

thoughtbot

Paperclip Demo is maintained by thoughtbot, inc

The names and logos for thoughtbot are trademarks of thoughtbot, inc.

License

Trail Map is licensed under the Creative Commons Attribution License.

paperclip_demo's People

Contributors

harlow avatar djcp avatar edwardloveall avatar homakov avatar maryschmidt avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.