movement 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 1b2ab178baaf418fb4aa1f70daa4b15f37a975c8
4
+ data.tar.gz: 6e755ab6d6e0076a13000c77d4f01346de929008
5
+ SHA512:
6
+ metadata.gz: 3121e6b6e75adfef8cedb849b8bb7dd4c1ed3ac01718565ef5cd9d2685f78f9a5fe7dc061f242eb46c6e1ce13380a422a97eff6b9b3579e37c8e0b1ccc9389e7
7
+ data.tar.gz: 325c28774c896b11a84979f081c17dd80052576eac45b1602b4181aa45701b93b7fcf1da9e3bd7ccba8878d5d7a91278f5e4a26370d05c6981549a338faf3fe1
data/.gitignore ADDED
@@ -0,0 +1,14 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
10
+ *.bundle
11
+ *.so
12
+ *.o
13
+ *.a
14
+ mkmf.log
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in movement.gemspec
4
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2014 Jack Dean Watson-Hamblin
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,41 @@
1
+ # Movement
2
+
3
+ "Movement is to RubyMotion as Rails is to Ruby."
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ Install it:
10
+
11
+ $ gem install movement
12
+
13
+ Start it:
14
+
15
+ $ movement new hello_world
16
+
17
+ Use it:
18
+
19
+ $ movement generate scaffold Task title:string notes:string due_at:datetime
20
+
21
+ Enjoy it:
22
+
23
+ $ rake
24
+
25
+ ## Project mission
26
+
27
+ This project is just an idea at the moment. You can already see from the installation "instructions" (they don't work) what the basic idea is though.
28
+
29
+ iOS, OS X, and Android can be daunting at times, but so was the world of dynamic web applications and we solved that too didn't we.
30
+
31
+ If you have ideas, open up an Issue on GitHub and start putting your thoughts into it.
32
+
33
+ ## Contributing
34
+
35
+ Biggest thing right now is to start getting code written and something working, but just as important is feedback and ideas for how YOU want to use it. Open up some issues with feature requests.
36
+
37
+ 1. Fork it ( https://github.com/FluffyJack/movement/fork )
38
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
39
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
40
+ 4. Push to the branch (`git push origin my-new-feature`)
41
+ 5. Create a new Pull Request
data/Rakefile ADDED
@@ -0,0 +1,2 @@
1
+ require "bundler/gem_tasks"
2
+
data/bin/move ADDED
@@ -0,0 +1,9 @@
1
+ #!/usr/bin/env ruby
2
+ lib = File.expand_path('../../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require "rubygems"
5
+ require "thor"
6
+ require "active_support/all"
7
+ require "movement/commands"
8
+
9
+ Movement::Commands::Core.start
data/lib/movement.rb ADDED
@@ -0,0 +1,5 @@
1
+ require "movement/version"
2
+
3
+ module Movement
4
+ # Your code goes here...
5
+ end
@@ -0,0 +1,9 @@
1
+ require "movement/commands/generate"
2
+
3
+ module Movement
4
+ module Commands
5
+ class Core < Thor
6
+ register(Commands::Generate, "generate", "generate", "Generate resources for your app")
7
+ end
8
+ end
9
+ end
@@ -0,0 +1,21 @@
1
+ module Movement
2
+ module Commands
3
+ class Generate < Thor::Group
4
+ include Thor::Actions
5
+
6
+ argument :generator
7
+ argument :name
8
+ class_option :destination_root, default: "app"
9
+
10
+ def self.source_root
11
+ File.dirname(__FILE__)
12
+ end
13
+
14
+ def generate
15
+ if generator == "view"
16
+ template("templates/UIView.tt", "#{options[:destination_root]}/views/#{name}.rb")
17
+ end
18
+ end
19
+ end
20
+ end
21
+ end
@@ -0,0 +1,7 @@
1
+ class <%= name.camelize %> < UIView
2
+ def init
3
+ super
4
+
5
+ self
6
+ end
7
+ end
@@ -0,0 +1,3 @@
1
+ module Movement
2
+ VERSION = "0.0.1"
3
+ end
data/movement.gemspec ADDED
@@ -0,0 +1,25 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'movement/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "movement"
8
+ spec.version = Movement::VERSION
9
+ spec.authors = ["Jack Dean Watson-Hamblin"]
10
+ spec.email = ["info@fluffyjack.com"]
11
+ spec.summary = %q{Full Stack Framework for RubyMotion}
12
+ spec.description = %q{Movement is to RubyMotion as Rails is to Ruby.}
13
+ spec.homepage = "https://github.com/FluffyJack/movement"
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0")
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_development_dependency "bundler", "~> 1.7"
22
+ spec.add_development_dependency "rake", "~> 10.0"
23
+ spec.add_dependency "thor", "~> 0.19"
24
+ spec.add_dependency "activesupport", "~> 4.1"
25
+ end
data/spec/helper.rb ADDED
@@ -0,0 +1,24 @@
1
+ $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), "..", "lib"))
2
+ require "thor"
3
+ require "active_support/all"
4
+ require "stringio"
5
+ require "rspec"
6
+
7
+ RSpec.configure do |config|
8
+ def capture(stream)
9
+ begin
10
+ stream = stream.to_s
11
+ eval "$#{stream} = StringIO.new"
12
+ yield
13
+ result = eval("$#{stream}").string
14
+ ensure
15
+ eval("$#{stream} = #{stream.upcase}")
16
+ end
17
+
18
+ result
19
+ end
20
+
21
+ def destination_root
22
+ File.join(File.dirname(__FILE__), "sandbox")
23
+ end
24
+ end
@@ -0,0 +1,32 @@
1
+ require "helper"
2
+ require "movement/commands/generate"
3
+
4
+ module Movement
5
+ module Commands
6
+ describe Generate do
7
+ after do
8
+ ::FileUtils.rm_rf(destination_root)
9
+ end
10
+
11
+ context "view" do
12
+ it "creates the view file" do
13
+ command = Generate.new(["view", "hello"], { destination_root: destination_root })
14
+ capture(:stdout) { command.invoke_all }
15
+ expect(File.exist?(File.join(destination_root, "views/hello.rb"))).to be true
16
+ end
17
+
18
+ it "writes the basic class skeleton" do
19
+ command = Generate.new(["view", "hello"], { destination_root: destination_root })
20
+ capture(:stdout) { command.invoke_all }
21
+ expect(File.read(File.join(destination_root, "views/hello.rb"))).to include "class Hello < UIView"
22
+ end
23
+
24
+ it "can handle multi-word class/file names" do
25
+ command = Generate.new(["view", "hello_world"], { destination_root: destination_root })
26
+ capture(:stdout) { command.invoke_all }
27
+ expect(File.read(File.join(destination_root, "views/hello_world.rb"))).to include "class HelloWorld < UIView"
28
+ end
29
+ end
30
+ end
31
+ end
32
+ end
metadata ADDED
@@ -0,0 +1,117 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: movement
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - Jack Dean Watson-Hamblin
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-11-03 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.7'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.7'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: thor
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '0.19'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '0.19'
55
+ - !ruby/object:Gem::Dependency
56
+ name: activesupport
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '4.1'
62
+ type: :runtime
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '4.1'
69
+ description: Movement is to RubyMotion as Rails is to Ruby.
70
+ email:
71
+ - info@fluffyjack.com
72
+ executables:
73
+ - move
74
+ extensions: []
75
+ extra_rdoc_files: []
76
+ files:
77
+ - ".gitignore"
78
+ - Gemfile
79
+ - LICENSE.txt
80
+ - README.md
81
+ - Rakefile
82
+ - bin/move
83
+ - lib/movement.rb
84
+ - lib/movement/commands.rb
85
+ - lib/movement/commands/generate.rb
86
+ - lib/movement/commands/templates/UIView.tt
87
+ - lib/movement/version.rb
88
+ - movement.gemspec
89
+ - spec/helper.rb
90
+ - spec/movement/commands/generate_spec.rb
91
+ homepage: https://github.com/FluffyJack/movement
92
+ licenses:
93
+ - MIT
94
+ metadata: {}
95
+ post_install_message:
96
+ rdoc_options: []
97
+ require_paths:
98
+ - lib
99
+ required_ruby_version: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ required_rubygems_version: !ruby/object:Gem::Requirement
105
+ requirements:
106
+ - - ">="
107
+ - !ruby/object:Gem::Version
108
+ version: '0'
109
+ requirements: []
110
+ rubyforge_project:
111
+ rubygems_version: 2.4.2
112
+ signing_key:
113
+ specification_version: 4
114
+ summary: Full Stack Framework for RubyMotion
115
+ test_files:
116
+ - spec/helper.rb
117
+ - spec/movement/commands/generate_spec.rb