background preloader

Rails / Ruby

Facebook Twitter

Getting Started With Restful Authentication in Rails. In this article, we will use restful_authentication to add a user system to a simple Rails application.

Getting Started With Restful Authentication in Rails

This is great for those first starting out and need step-by-step directions for using this amazing plugin. At the end of the article, visitors will be able to create an account, reset their password, login, logout, and validate email addresses. The Basics This portion of the tutorial is very basic. All we will do is generate a simple application that allows users to create/read/update/destroy a record containing a movie name and rating. Generate the Application First we need to have rails generate the framework code. Generate the Movie Model Now we are going to the power of Rails generators to quickly produce the code and database for our basic application. Here we are telling rails that we want code generated to handle a "Movie" model, which as a string title and integer rating. This command will setup the database and create the table with the appropriate columns. Enhancements Styling. #199 Mobile Devices. #302 In-Place Editing. Edit an attribute in-place without leaving a page using the Best In Place gem.

#302 In-Place Editing

Learn how to add validations and support for various field types. Download: source codeProject Files in Zip (84.4 KB)mp4Full Size H.264 Video (18.5 MB)m4vSmaller H.264 Video (9.87 MB)webmFull Size VP8 Video (11.7 MB)ogvFull Size Theora Video (24.5 MB) Tutorials for Scala, Struts 2, HTML5, ANT, iBATIS, log4j, Hibernate, JSP, JAVA, JDBC, AJAX, WAP, SQL, MySQL, C/C++, PERL, PHP, Ruby, Ruby on Rails, Python, HTML, XHTML, CSS, CGI, Shell, Unix, JavaScript, jQuery, Radius, UML, GPRS, GSM,i-Mode, WiFi, WML, W. State of the Stack – A Ruby on Rails Benchmarking Report – Sept. 2011. A report on Ruby usage among New Relic Customers We saw recently that our friend Peter Cooper has created a nice tutorial on moving to Ruby 1.9 called The Ruby 1.9 Walkthrough: How to Go From Ruby 1.8.7 to 1.9.2 and 1.9.3.

State of the Stack – A Ruby on Rails Benchmarking Report – Sept. 2011

We started to wonder how many of our customers are on 1.8 versus 1.9, then quickly (and embarrassingly) realized we hadn’t published a Ruby on Rails State of the Stack Report in quite some time. Read the (overdue) report below. A little background Many of our customers have opted in to have their performance data shared with the Rails Core Team to aid in the team’s ongoing work on the platform. Most Commonly Deployed Ruby Versions. Facebook integration with Omniauth and Devise on Rails 3. A Resource for Web Application Developers. Cloud Application Platform. OmniAuth: Overview - GitHub. Since version 1.2, Devise supports integration with OmniAuth.

OmniAuth: Overview - GitHub

This wiki page will cover the basics to have this integration working using an OAuth provider as example. Since version 1.5, Devise supports OmniAuth 1.0 forward which will be the version covered by this tutorial. Before you start Remember that config.omniauth adds omniauth provider middleware to your application. This means you should not add this provider middleware again in config/initializers/omniauth.rb as they'll clash with each other and result in always-failing authentication.

Facebook example The first step then is to add an OmniAuth gem to your application. Gem 'omniauth-facebook' Here we'll use Facebook as an example, but you are free to use whatever and as many OmniAuth gems as you'd like. Next up, you should add the columns "provider" and "uid" to your User model. rails g migration AddColumnsToUsers provider uid rake db:migrate require "omniauth-facebook"config.omniauth :facebook, "APP_ID", "APP_SECRET"

How to Use Omniauth to Authenticate your Users. I hate signing up for websites.

How to Use Omniauth to Authenticate your Users

I’ve already signed up for so many, using different usernames, that going back to one of them and trying to remember my credentials is sometimes impossible. These days, most sites have begun offering alternative ways to sign up, by allowing you to use your Facebook, Twitter or even your Google account. Creating such an integration sometimes feels like a long and arduous task. Intridea/omniauth - GitHub. Ruby on rails - I ran the command "rake test" and I get this error. Ruby on Rails Tutorial: Learn Rails by Example. Michael Hartl Contents Foreword My former company (CD Baby) was one of the first to loudly switch to Ruby on Rails, and then even more loudly switch back to PHP (Google me to read about the drama).

Ruby on Rails Tutorial: Learn Rails by Example

Ruby on Rails Plugins. 10 Ruby on Rails 3 Tips That Will Make You a Better Rails Programmer. If you already are a Rails programmer, or if you are just beginning to learn about rails in your computer programming classes, i’m pretty sure that you have already been dazzled by the things that Rails can do for you.

10 Ruby on Rails 3 Tips That Will Make You a Better Rails Programmer

However, all this convenience comes at a cost. That cost comes for the fact that you need to know how to work with the internal Rails conventions and traps. Since i’ve been programming in Rails for quite some months now, i would like to give you what i think are some very useful tips that will make your Rails life easier. Building a Social Network Site in Rails. I’m not going to cover how to actually code an entire social network site in rails as all social network sites vary in their functionality (and it’ll take too long).

Building a Social Network Site in Rails

I will cover plugins and other things you might find useful though. Quick Start If you don’t really want to do the coding but want to get a site up and running and soon as possible, you may want to have a look at Lovd by Less by the guys over at Less Everything. Lovd by Less contains user signups, galleries, blogs, comments and various other things that you might want, so it’s a great starting block for your site. Panda - Video encoding service, REST API and open source platform. 23 Amazing And Open Source Ruby On Rails Applications.

Home » Extras » 23 Amazing And Open Source Ruby On Rails Applications Ruby on Rails is a powerful web framework that helps creating web applications easier, faster & writing an organized code.

23 Amazing And Open Source Ruby On Rails Applications

There are lots of websites that use it including popular ones like Twitter, Basecamp, AboutUs & many more. Also, Ruby on Rails powers some amazing open source web applications which you may want to use directly or improve further. Here is a well-categorized 23 open source Ruby on Rails applications: (Note: There are few Merb apps. in the list too which we believe is ok considering Rails & Merb are getting into the same package with Rails 3.) Project, Task & Time Management. A Social Networking Plugin for Ruby on Rails.

Run Background Jobs in the Cloud. Tim Berners-Lee on the next Web. Gary Flake: is Pivot a turning point for web exploration? Profile on TED.com. 7 reasons I switched back to PHP after 2 years on Rails - O'Reilly Ruby. Automated Testing Suites in Ruby on Rails « Kansas City on Rails. Automated Testing Suites in Ruby on Rails Make no mistake: web applications are not documents, they are software. While a simple brochure-style site may contain nothing more than static HTML pages, your typical Ruby on Rails application is something more. After all, if you only need a few static pages to your site, there’s no reason to bring Rails into the mix to begin with. Web applications have evolved into sophisticated beasts. How much “sophistication” or “beast” you see largely depends on the caliber of developer you hire.

Ruby on Rails makes it easy for developers to test the code they write. Here’s a list of good test-related questions to ask any Ruby on Rails developer you’re considering: Do you practice Test Driven Development? Testing vs. In the beginning of a project, you won’t be able to tell if a good test suite is being developed. Test suites are about keeping the code maintainable for the long term. Like this: Like Loading... Teach Me To Code — Writing Code is the Easy Part. Rails Forum - Ruby on Rails Help and Discussion Forum. Ruby on Rails Screencasts. Ruby on Rails Guides. Rails 3.0.3 Setup – Delicious Clone. Would Ruby on Rails suit my work..