Skip to content
Browse files

fix the build process

BubbleWrap has changed how they require files and broke older gem settings.
  • Loading branch information...
1 parent 1a7aacb commit d0c4a9e01f175a17017664e45c4dc90af8e9b474 @clayallsopp clayallsopp committed Jun 8, 2012
Showing with 21 additions and 12 deletions.
  1. +2 −0 Gemfile
  2. +14 −1 Rakefile
  3. +4 −11 lib/remote_model.rb
  4. +1 −0 remote_model.gemspec
View
2 Gemfile
@@ -1,4 +1,6 @@
source "http://rubygems.org"
+gem 'bubble-wrap'
+
# Specify your gem's dependencies in remote_model.gemspec
gemspec
View
15 Rakefile
@@ -1 +1,14 @@
-require "bundler/gem_tasks"
+#!/usr/bin/env rake
+$:.unshift("/Library/RubyMotion/lib")
+require 'motion/project'
+require "bundler/gem_tasks"
+Bundler.setup
+Bundler.require
+
+$:.unshift("./lib/")
+require './lib/remote_model'
+
+Motion::Project::App.setup do |app|
+ # Use `rake config' to see complete project settings.
+ app.name = 'RemoteModel'
+end
View
15 lib/remote_model.rb
@@ -1,12 +1,5 @@
require "remote_model/version"
-require "bubble-wrap"
-
-unless defined?(Motion::Project::Config)
- raise "This file must be required within a RubyMotion project Rakefile."
-end
-
-Motion::Project::App.setup do |app|
- Dir.glob(File.join(File.dirname(__FILE__), 'remote_model/*.rb')).each do |file|
- app.files.unshift(file)
- end
-end
+require 'bubble-wrap'
+Dir.glob(File.join(File.dirname(__FILE__), 'remote_model/*.rb')).each do |file|
+ BW.require file
+end
View
1 remote_model.gemspec
@@ -15,4 +15,5 @@ Gem::Specification.new do |s|
s.require_paths = ["lib"]
s.add_dependency "bubble-wrap"
+ s.add_development_dependency 'rake'
end

0 comments on commit d0c4a9e

Please sign in to comment.
Something went wrong with that request. Please try again.