Teach Me To Code » Screencasts (iPhone/iPod) show

Teach Me To Code » Screencasts (iPhone/iPod)

Summary: Video tutorials on a variety of subjects including Ruby, Rails, CSS, HTML, Groovy, Grails, and other web technologies.

Join Now to Subscribe to this Podcast

Podcasts:

 My Podcasting Setup | File Type: video/quicktime | Duration: Unknown

My Equipment: Mackie PROFX12 12-Channel Compact Effects Mixer with USB Sony MDR7506 Professional Large Diaphragm Headphone Roland R-05 Studio WAVE/MP3 Recorder Transcend 32 GB Class 10 SDHC Flash Memory Card (TS32GSDHC10E) (for the Roland R-05) Griffin Technology iMic USB Audio Device Doctor Who TARDIS USB Hub Doctor Who TARDIS USB Hub Model #DR115 QuickVoice Recorder Rolls MM11 Microphone Muting Switch Designed to Temporarily Mute a Balanced XLR Signal Heil PR-40 Dynamic Studio Recording Microphone Heil Sound SM-2 Shockmount for PR-30 and PR-40 Champagne Heil Sound PL-2T Overhead Broadcast Boom (Standard) Podcasting Club Setup: Behringer Xenyx 802 Premium 8-Input 2-Bus Mixer with Xenyx Mic Preamps and British EQs Shure SM58-CN Cardioid Dynamic Vocal Microphone with Cable On Stage Foam Ball-Type Mic Windscreen, Black Hamilton Nu-Era Tabletop Mic Stand JVC HA-V570 Supra-Aural Headphones

 Upgrading JotRod to Rails 3.1.3 | File Type: video/x-m4v | Duration: Unknown

When preparing to add some layout features to JotRod, I realized it was a Rails 3.0.9 application. Here's a quick rundown on upgrading to Rails 3.1.3. Download 164.7 MB Download (iPod & iPhone) 37.9 MB Take the 2011 Readers Survey

 Followers and Following | File Type: video/x-m4v | Duration: Unknown

In order to get someone a timeline in JotRod, we need followers and following lists to compile the Jots from. This means that we need to add a new ColumnFamily called Followers and another one called Following. We don't have the joins capability from relational databases to do this for us. I'm going to hijack the User model's database connection to create the ColumnFamilies. (We don't have migrations, yet.) Here's what I ran in the rails console: cf_def = CassandraThrift::CfDef.new(:keyspace => "JotRod", :name => "Followers") User.connection.add_column_family(cf_def) cf_def = CassandraThrift::CfDef.new(:keyspace => "JotRod", :name => "Following") User.connection.add_column_family(cf_def) Now that we have the ColumnFamilies, I want to have syntax like this to define the relationships on the User model: list :followers, :User list :following, :User This should provide the following API: #followers - returns an array of users as specified from the Followers ColumnFamily #followers

 ActiveModel Callbacks | File Type: video/x-m4v | Duration: Unknown

In the Jots (like tweets) in JotRod, I needed to generate a hash on creation as the key for the Jots. So, I determined that the easiest way to do that was to include ActiveModel Callbacks. The module is pretty simple to add to your classes. Here's a demo of how to add it to Sandra. Sandra's repository JotRod's repository Download 223 MB Download (iPod & iPhone) 37 MB Take the 2011 Readers Survey

 Model Generator | File Type: video/x-m4v | Duration: Unknown

Here's an introduction to creating a Rails connector gem for an ORM with a model generator. Download 352.3 MB Download (iPod & iPhone) 84.7 MB Take the 2011 Readers Survey

 Introduction to Sandra: The Cassandra ORM | File Type: video/x-m4v | Duration: Unknown

When I started playing with Cassandra, I wound up writing part of an ORM to get what I needed from it. I want to build actual projects with Rails, Ruby, or other technologies for my videos rather than just narrowly demonstrate a piece of technology. So, I'm bringing you up to speed with Sandra so that as I continue with the Twitter Clone, you'll know what I'm using and why I'm adding things to it. Sandra is available on Github at https://github.com/charlesmaxwood/sandra Download 531.0 MB Download (iPod & iPhone) 111.8 MB Take the 2011 Readers Survey

 Ruby Koans | File Type: video/x-m4v | Duration: Unknown

I’m working on another Cassandra demo, but didn’t have time to finish, so I decided to show you Ruby Koans. It’s a very interesting test-driven approach to learning Ruby. I hope you enjoy it. Download 52.5 MB Download (iPod & iPhone) 31.1 MB Take the 2011 Readers Survey

 Cassandra Basic Schema and Ruby Gem | File Type: video/x-m4v | Duration: Unknown

You can get cassandra at cassandra.apache.org and the ruby gem by running: gem install cassandra I did run into a problem with the trift_client gem when installing. If you get a Load Error, run this. sudo chmod 644 /usr/local/lib/ruby/gems/1.8/gems/thrift_client-0.6.3/lib/thrift_client/*.rb sudo chmod 755 /usr/local/lib/ruby/gems/1.8/gems/thrift_client-0.6.3/lib/thrift_client/connection Here are some of the Cassandra commands from the video: #connects to the cassandra server using the Twitter keyspace store = Cassandra.new(“Twitter”) # create a new column family in the Twitter keyspace called Users cf_def = CassandraThrift::CfDef.new(:keyspace => “Twitter”, :name => “Users”) store.add_column_family(cf_def) # add or create a row to the column family store.insert(“Users”, “cmaxw”, {“name” => “Charles Max Wood”, “description” => “Awesome coder”}) # remove a column from a row store.remove(“Users”, “cmaxw”, “description”) Download 17.2 MB Download (iPod & iPhone) 20.9 MB Take the 2011 Readers Survey

 Create a ‘Like’ or ‘+1′ button with make_flaggable | File Type: video/x-m4v | Duration: Unknown

With the recent release of the Google Plus beta (ask me for an invite if you want one), I felt it appropriate to show a simple way to create a Like or +1 button for your Rails application. The app and concept is pretty simple, so I won't worry about posting the code below. Install: gem 'make_flaggable', :git => 'git://github.com/cavneb/make_flaggable.git' bundle install rails generate make_flaggable rake db:migrate Models: class Article

 Building a Star-Rating System in Ruby on Rails with jQuery | File Type: video/x-m4v | Duration: Unknown

Specification Clicking a star rating turns on the stars to the left of the star I clicked. Clicking a star submits the star rating. When I refresh the page, the star ratings should be persistent. We’ll be using Rails’ functions including: form_for hidden_field Rails Helpers We’ll be using jQuery functions including: click each ajax {:id => form_id , :class => "star_rating_form"} do |f| %> form_id + "_stars" %> var set_stars = function(form_id, stars) { for(i=1; i

 Capistrano: Deploying Ruby on Rails Applications to Multiple Servers | File Type: video/x-m4v | Duration: Unknown

For a basic deployment recipe, check out Basic Deployment with Capistrano This episode demonstrates how to extend deployment to deploy to stage and production. Overall it’s rather simple. All it entails is creating a new task for each stage you want to deploy to with the settings you need changed. Here’s an example: task :stage do role :web, "stage.teachmetocodeacademy.com" # Your HTTP server, Apache/etc role :app, "stage.teachmetocodeacademy.com" # This may be the same as your `Web` server role :db, "stage.teachmetocodeacademy.com", :primary => true # This is where Rails migrations will run set :deploy_to, '/var/www/stage-teachmetocodeacademy/' set :user, 'deploy' end That will allow you to run `cap stage deploy` to deploy to your staging environment.   Download 55.3 MB Download (iPod & iPhone) 35.1 MB

 Polymorphism with Many-to-Many Associations – A Teach Me To Code Tutorial | File Type: video/x-m4v | Duration: 20:03

Polymorphic associations are very simple, as are many-to-many associations. When you blend the two, it's not nearly as simple. Since there isn't a working build-in mechanism for many-to-many polymorphic associations. Here's a quick demo of what happens if you try to set up a traditional has_many :through association with a polymorphic association. I also show how to set things up so you can get the associated objects. Download 101.3 MB Download (iPod & iPhone) 45.5 MB

 Many to Many Associations in Ruby on Rails – A Teach Me To Code Tutorial | File Type: video/x-m4v | Duration: Unknown

I had several requests in UserVoice to provide a Many to Many tutorial in Rails. This is a demonstration of how to put together a "has and belongs to many" association and a "has many through" association. This is somewhat basic to Ruby on Rails, but important if you need to associate different models. Download 161.3 MB Download iPhone & iPod 97.7 MB

 Acceptance Tests with RSpec and Capybara | File Type: video/x-m4v | Duration: 27:14

On the Ruby Rogues podcast I mentioned that I had moved away from Cucumber to RSpec and Capybara for my integration tests. Here's a demo on how to do some TDD with RSpec and Capybara. Download 180.6 MB Download iPhone & iPod 109.2 MB

 CoffeeScript: The Cool Parts | File Type: video/x-m4v | Duration: 22:23

CoffeeScript offers more than nice syntax for setting and managing data and functions. It also offers Classes, Inheritance, access to a 'super' method, Ruby-style string interpolation, easy variable and function bindings, and chained comparisons. Here's the code I showed in the video: class Vehicle constructor: (@name) -> move: (miles) -> console.log @name + " drove " + miles + " miles." class VWBug extends Vehicle move: -> console.log "Cruisin'..." super 100 class Truck extends Vehicle move: -> console.log "Haulin'..." super 50 mater = new Truck "Mater" herbie = new VWBug "Herbie" mater.move() herbie.move() a1c = "7.6" healthy = 7.0 > a1c > 5.0 console.log "A1C within healthy range: #{a1c}" Account = (customer, cart) -> @customer = customer @cart = cart $('.shopping_cart').click (event) => @customer.purchase @cart If you're new to CoffeeScript, make sure you check out the CoffeeScript Cookbook and CoffeeScript Basics. Download 150.3 MB Download (iPod & iPhone) 87.1 MB

Comments

Login or signup comment.