ib 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -24,16 +24,15 @@ $:.unshift("/Library/RubyMotion/lib")
24
24
  require 'motion/project'
25
25
 
26
26
  # if you use bundler
27
- require 'bundler/setup'
28
- Bundler.setup
29
-
30
- # require 'ib tasks'
31
- require 'ib/tasks'
27
+ require 'bundler'
28
+ Bundler.require
32
29
 
30
+ # if you are not using bundler
31
+ require 'rubygems'
32
+ require 'ib'
33
33
 
34
34
  Motion::Project::App.setup do |app|
35
35
  # ...
36
- app.files.unshift IB::PATH # add ib module
37
36
  end
38
37
 
39
38
  ```
data/lib/ib.rb CHANGED
@@ -1,10 +1,17 @@
1
- module IB
2
-
3
- def ib_outlet name, type
4
- # maybe call attr_accessor here?
5
- end
6
-
7
- def ib_action name
1
+ if defined?(Motion::Project::Config)
2
+ Motion::Project::App.setup do |app|
3
+ app.files.unshift File.join(File.dirname(__FILE__), 'ib/outlets.rb')
8
4
  end
5
+ end
9
6
 
7
+ module IB
10
8
  end
9
+
10
+ require 'fileutils'
11
+ require 'xcodeproj'
12
+
13
+ require 'ib/tasks'
14
+ require 'ib/parser'
15
+ require 'ib/version'
16
+ require 'ib/generator'
17
+ require 'ib/project'
data/lib/ib/generator.rb CHANGED
@@ -1,8 +1,3 @@
1
- require 'fileutils'
2
- require 'ib/version'
3
- require 'ib/parser'
4
- require 'xcodeproj'
5
-
6
1
  class IB::Generator
7
2
  def write src, dest
8
3
  files = IB::Parser.new.find_all(src)
data/lib/ib/outlets.rb ADDED
@@ -0,0 +1,10 @@
1
+ module IB
2
+
3
+ def ib_outlet name, type
4
+ # maybe call attr_accessor here?
5
+ end
6
+
7
+ def ib_action name
8
+ end
9
+
10
+ end
data/lib/ib/project.rb CHANGED
@@ -1,8 +1,3 @@
1
- require 'fileutils'
2
- require 'ib/parser'
3
- require 'ib/generator'
4
- require 'xcodeproj'
5
-
6
1
  class IB::Project
7
2
  def write app_path = "./app", resources_path = "./resources"
8
3
  project = Xcodeproj::Project.new
data/lib/ib/tasks.rb CHANGED
@@ -1,13 +1,7 @@
1
- require "ib"
2
- require "ib/project"
3
- require "rake"
1
+ require 'rake'
4
2
 
5
3
  desc "Generates ui.xcodeproj and open it"
6
4
  task "design" do
7
5
  IB::Project.new.write
8
6
  system "open ui.xcodeproj"
9
- end
10
-
11
- module IB
12
- PATH = File.expand_path("../ib.rb", File.dirname(__FILE__))
13
7
  end
data/lib/ib/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module IB
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
data/spec/spec_helper.rb CHANGED
@@ -2,7 +2,9 @@
2
2
  # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
3
3
  # Require this file using `require "spec_helper.rb"` to ensure that it is only
4
4
  # loaded once.
5
- #
5
+
6
+ require 'ib'
7
+
6
8
  # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
7
9
  RSpec.configure do |config|
8
10
  config.treat_symbols_as_metadata_keys_with_true_values = true
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ib
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -59,6 +59,7 @@ files:
59
59
  - ib.gemspec
60
60
  - lib/ib.rb
61
61
  - lib/ib/generator.rb
62
+ - lib/ib/outlets.rb
62
63
  - lib/ib/parser.rb
63
64
  - lib/ib/project.rb
64
65
  - lib/ib/tasks.rb
@@ -84,7 +85,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
84
85
  version: '0'
85
86
  segments:
86
87
  - 0
87
- hash: -2447357950835511794
88
+ hash: -3342148474886452846
88
89
  required_rubygems_version: !ruby/object:Gem::Requirement
89
90
  none: false
90
91
  requirements:
@@ -93,7 +94,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
93
94
  version: '0'
94
95
  segments:
95
96
  - 0
96
- hash: -2447357950835511794
97
+ hash: -3342148474886452846
97
98
  requirements: []
98
99
  rubyforge_project:
99
100
  rubygems_version: 1.8.24