The Ruby on Rails Tutorial, 2nd Edition book and screencast series teach you how to develop and deploy real, industrial-strength web applications with Ruby on Rails, the open-source web framework that powers top websites such as Twitter, Hulu, GitHub, and the Yellow Pages.
The Rails Tutorial screencasts contain dozens of tips and tricks to help you go beyond the Rails Tutorial book, including debugging hints, test-driven development techniques, and solutions to many of the book’s exercises (view a sample video or some free screencasts). And though the screencasts are carefully edited, I’ve left in some of the problems I encountered along the way, so that you can learn how to recover from the inevitable application errors – and see that even experts sometimes make mistakes.
New in the 2nd Edition
Fully updated for Rails 3.2 and Ruby 1.9
All-new design using Twitter’s Bootstrap
Coverage of the new asset pipeline, including Sprockets & Sass
Behavior-driven development (BDD) with Capybara & RSpec
Better automated testing with Guard & Spork
Roll your own authentication with has_secure_password
An introduction to Gherkin & Cucumber
All-new design using Twitter’s Bootstrap
Coverage of the new asset pipeline, including Sprockets & Sass
Behavior-driven development (BDD) with Capybara & RSpec
Better automated testing with Guard & Spork
Roll your own authentication with has_secure_password
An introduction to Gherkin & Cucumber
Table of content
Chapter 1 From zero to deploy
1.1 Introduction
1.1.1 Comments for
various readers
1.1.2 “Scaling†Rails
1.1.3 Conventions
in this book
1.2 Up and running
1.2.1 Development
environments
1.
IDEs
2.
Text editors and command
lines
3.
Browsers
4.
A note about tools
1.2.2 Ruby,
RubyGems, Rails, and Git
1.
Rails Installer (Windows)
2.
Install Git
3.
Install Ruby
4.
Install RubyGems
5.
Install Rails
1.2.3 The first
application
1.2.4 Bundler
1.2.5 rails server
1.2.6
Model-view-controller (MVC)
1.3 Version control with Git
1.3.1 Installation
and setup
1.
First-time system setup
2.
First-time repository setup
1.3.2 Adding and
committing
1.3.3 What good
does Git do you?
1.3.4 GitHub
1.3.5 Branch,
edit, commit, merge
1.
Branch
2.
Edit
3.
Commit
4.
Merge
5.
Push
1.4 Deploying
1.4.1 Heroku setup
1.4.2 Heroku
deployment, step one
1.4.3 Heroku
deployment, step two
1.4.4 Heroku
commands
1.5 Conclusion
Chapter 2 A demo app
2.1 Planning the application
2.1.1 Modeling
demo users
2.1.2 Modeling
demo microposts
2.2 The Users resource
2.2.1 A user tour
2.2.2 MVC in
action
2.2.3 Weaknesses
of this Users resource
2.3 The Microposts resource
2.3.1 A micropost
microtour
2.3.2 Putting the
micro in microposts
2.3.3 A user
has_many microposts
2.3.4 Inheritance
hierarchies
2.3.5 Deploying
the demo app
2.4 Conclusion
Chapter 3 Mostly static pages
3.1 Static pages
3.1.1 Truly static
pages
3.1.2 Static pages
with Rails
3.2 Our first tests
3.2.1 Test-driven
development
3.2.2 Adding a
page
1.
Red
2.
Green
3.
Refactor
3.3 Slightly dynamic pages
3.3.1 Testing a
title change
3.3.2 Passing
title tests
3.3.3 Embedded
Ruby
3.3.4 Eliminating
duplication with layouts
3.4 Conclusion
3.5 Exercises
3.6 Advanced setup
3.6.1 Eliminating
bundle exec
1.
RVM Bundler integration
2.
binstubs
3.6.2 Automated
tests with Guard
3.6.3 Speeding up
tests with Spork
1.
Guard with Spork
3.6.4 Tests inside
Sublime Text
Chapter 4 Rails-flavored Ruby
4.1 Motivation
4.2 Strings and methods
4.2.1 Comments
4.2.2 Strings
1.
Printing
2.
Single-quoted strings
4.2.3 Objects and
message passing
4.2.4 Method
definitions
4.2.5 Back to the
title helper
4.3 Other data structures
4.3.1 Arrays and
ranges
4.3.2 Blocks
4.3.3 Hashes and
symbols
4.3.4 CSS
revisited
4.4 Ruby classes
4.4.1 Constructors
4.4.2 Class
inheritance
4.4.3 Modifying
built-in classes
4.4.4 A controller
class
4.4.5 A user class
4.5 Conclusion
4.6 Exercises
Chapter 5 Filling in the layout
5.1 Adding some structure
5.1.1 Site
navigation
5.1.2 Bootstrap
and custom CSS
5.1.3 Partials
5.2 Sass and the asset pipeline
5.2.1 The asset
pipeline
1.
Asset directories
2.
Manifest files
3.
Preprocessor engines
4.
Efficiency in production
5.2.2
Syntactically awesome stylesheets
1.
Nesting
2.
Variables
5.3 Layout links
5.3.1 Route tests
5.3.2 Rails routes
5.3.3 Named routes
5.3.4 Pretty RSpec
5.4 User signup: A first step
5.4.1 Users
controller
5.4.2 Signup URI
5.5 Conclusion
5.6 Exercises
Chapter 6 Modeling users
6.1 User model
6.1.1 Database
migrations
6.1.2 The model
file
1.
Model annotation
2.
Accessible attributes
6.1.3 Creating
user objects
6.1.4 Finding user
objects
6.1.5 Updating
user objects
6.2 User validations
6.2.1 Initial user
tests
6.2.2 Validating
presence
6.2.3 Length
validation
6.2.4 Format
validation
6.2.5 Uniqueness
validation
1.
The uniqueness caveat
6.3 Adding a secure password
6.3.1 An encrypted
password
6.3.2 Password and
confirmation
6.3.3 User
authentication
6.3.4 User has
secure password
6.3.5 Creating a
user
6.4 Conclusion
6.5 Exercises
Chapter 7 Sign up
7.1 Showing users
7.1.1 Debug and
Rails environments
7.1.2 A Users
resource
7.1.3 Testing the
user show page (with factories)
7.1.4 A Gravatar
image and a sidebar
7.2 Signup form
7.2.1 Tests for
user signup
7.2.2 Using
form_for
7.2.3 The form
HTML
7.3 Signup failure
7.3.1 A working
form
7.3.2 Signup error
messages
7.4 Signup success
7.4.1 The finished
signup form
7.4.2 The flash
7.4.3 The first
signup
7.4.4 Deploying to
production with SSL
7.5 Conclusion
7.6 Exercises
Chapter 8 Sign in, sign out
8.1 Sessions and signin failure
8.1.1 Sessions
controller
8.1.2 Signin tests
8.1.3 Signin form
8.1.4 Reviewing
form submission
8.1.5 Rendering
with a flash message
8.2 Signin success
8.2.1 Remember me
8.2.2 A working
sign_in method
8.2.3 Current user
8.2.4 Changing the
layout links
8.2.5 Signin upon
signup
8.2.6 Signing out
8.3 Introduction to Cucumber
(optional)
8.3.1 Installation
and setup
8.3.2 Features and
steps
8.3.3
Counterpoint: RSpec custom matchers
8.4 Conclusion
8.5 Exercises
Chapter 9 Updating, showing, and deleting users
9.1 Updating users
9.1.1 Edit form
9.1.2 Unsuccessful
edits
9.1.3 Successful
edits
9.2 Authorization
9.2.1 Requiring
signed-in users
9.2.2 Requiring
the right user
9.2.3 Friendly
forwarding
9.3 Showing all users
9.3.1 User index
9.3.2 Sample users
9.3.3 Pagination
9.3.4 Partial
refactoring
9.4 Deleting users
9.4.1
Administrative users
1.
Revisiting attr_accessible
9.4.2 The destroy
action
9.5 Conclusion
9.6 Exercises
Chapter 10 User microposts
10.1 A Micropost model
10.1.1 The basic
model
10.1.2 Accessible
attributes and the first validation
10.1.3
User/Micropost associations
10.1.4 Micropost
refinements
1.
Default scope
2.
Dependent: destroy
10.1.5 Content
validations
10.2 Showing microposts
10.2.1 Augmenting
the user show page
10.2.2 Sample
microposts
10.3 Manipulating microposts
10.3.1 Access control
10.3.2 Creating
microposts
10.3.3 A
proto-feed
10.3.4 Destroying
microposts
10.4 Conclusion
10.5 Exercises
Chapter 11 Following users
11.1 The Relationship model
11.1.1 A problem
with the data model (and a solution)
11.1.2
User/relationship associations
11.1.3 Validations
11.1.4 Followed
users
11.1.5 Followers
11.2 A web interface for following
users
11.2.1 Sample
following data
11.2.2 Stats and a
follow form
11.2.3 Following
and followers pages
11.2.4 A working
follow button the standard way
11.2.5 A working
follow button with Ajax
11.3 The status feed
11.3.1 Motivation
and strategy
11.3.2 A first
feed implementation
11.3.3 Subselects
11.3.4 The new
status feed
1.4 Conclusion
11.4.1 Extensions
to the sample application
1.
Replies
2.
Messaging
3.
Follower notifications
4.
Password reminders
5.
Signup confirmation
6.
RSS feed
7.
REST API
8.
Search
11.4.2 Guide to
further resources
11.5 Exercises
Uploaded.net
- http://ul.to/uyquuytl
- http://ul.to/bymbmjk1
- http://ul.to/5vyvwbp0
- http://ul.to/1gvurspw
- http://ul.to/wwhfoth4
- http://ul.to/98oif97j
- http://bit.ly/OreCap
- http://bit.ly/1bZyGeG
- http://bit.ly/1guAvgt
- http://bit.ly/MRz7MB
- http://bit.ly/1pfgK2W
- http://bit.ly/1feIlbz
cloudzer.net
- http://clz.to/e0dah38k
- http://clz.to/c85fp13a
- http://clz.to/3y18m19w
- http://clz.to/5l6ugie2
- http://clz.to/o7yqupwu
- http://clz.to/ii69y20c
No comments:
Post a Comment