Setting Up the Project

Create our RubyMotion project with motion create Colr. To keep our project organized, add the following files and their directories:

  • ./app/controllers/search_controller.rb
  • ./app/controllers/color_controller.rb
  • ./app/models/color.rb
  • ./app/models/tag.rb

It already feels like a big fancy app, doesn’t it? Now we need to add BubbleWrap to our project. Earlier we used BubbleWrap to clean up key-value observing, but it also includes pleasant wrappers for HTTP requests. Refer to Changing Models with Key-Value Observing for detailed instructions, but essentially what we do is install the bubble-wrap gem and require it in our Rakefile.

Now that we have the pieces in place, it’s time to start writing some code.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset