motion-generators 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +7 -4
- data/lib/motion/generate.rb +2 -4
- data/lib/motion/generators/version.rb +1 -1
- data/lib/motion/templates/ui_table_view_controller.rb.erb +3 -1
- data/lib/motion/templates/ui_view_controller.rb.erb +3 -1
- metadata +1 -2
- data/LICENSE.txt +0 -21
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4e881160d18d8ccbc8207274d64184a25e3b13c2
|
4
|
+
data.tar.gz: 81249d85243d993ec591b572d4aa2c7e0b11dd01
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b2e7564cb34e99134a2093bd4c2434e589bd6c34bafb3ce2181d6aa5582fdc86e701951fee3fe075ff76f0a6cfb320712fe9db6d0d1955b1edc10c2343c34264
|
7
|
+
data.tar.gz: bab339e13aaec41435d6758819736b92d152b5441efe04bbf99901b8bfc49ad5b60f906663bbce4b1fc3c0ecc6bd788822eea15a4ea5e3c872600140405f7b01
|
data/README.md
CHANGED
@@ -36,19 +36,22 @@ To see a full list of what's available, do
|
|
36
36
|
motion-generate ui_table_view_controller # Creates a UIViewController subclass in app/controllers
|
37
37
|
motion-generate ui_view_controller # Creates a UIViewController subclass in app/controllers
|
38
38
|
|
39
|
+
### Example
|
39
40
|
|
40
|
-
|
41
|
+
$ motion-generate ui_table_view_controller skateboards
|
41
42
|
|
42
|
-
After checking out the repo, run `bin/setup` to install dependencies. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
43
43
|
|
44
|
-
|
44
|
+
Will generate a file named **app/controllers/skateboards_controller.rb** that looks something like [this template](lib/motion/templates/ui_table_view_controller.rb.erb)
|
45
45
|
|
46
46
|
## Contributing
|
47
47
|
|
48
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
48
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/KatanaCode/motion-generators.
|
49
49
|
|
50
50
|
|
51
51
|
## License
|
52
52
|
|
53
53
|
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
|
54
54
|
|
55
|
+
## Credit
|
56
|
+
|
57
|
+
Created by [Katana—App developers in Edinburgh, Scotland](http://katanacode.com)
|
data/lib/motion/generate.rb
CHANGED
@@ -25,7 +25,6 @@ module Motion
|
|
25
25
|
desc "ui_view_controller", "Creates a UIViewController subclass in app/controllers"
|
26
26
|
def ui_view_controller(name)
|
27
27
|
@name = name
|
28
|
-
@parent_class_name = options[:parent_class].camelize
|
29
28
|
template "ui_view_controller.rb.erb", "app/controllers/#{name}_controller.rb"
|
30
29
|
end
|
31
30
|
|
@@ -39,7 +38,6 @@ module Motion
|
|
39
38
|
desc "ui_table_view_controller", "Creates a UITableViewController subclass in app/controllers"
|
40
39
|
def ui_table_view_controller(name)
|
41
40
|
@name = name
|
42
|
-
@parent_class_name = options[:parent_class].camelize
|
43
41
|
template "ui_view_controller.rb.erb", "app/controllers/#{name}_controller.rb"
|
44
42
|
end
|
45
43
|
|
@@ -49,11 +47,11 @@ module Motion
|
|
49
47
|
|
50
48
|
|
51
49
|
def parent_class_name
|
52
|
-
|
50
|
+
options[:parent_class].camelize
|
53
51
|
end
|
54
52
|
|
55
53
|
def class_name
|
56
|
-
@name.camelize
|
54
|
+
"%sController" % @name.camelize
|
57
55
|
end
|
58
56
|
|
59
57
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: motion-generators
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bodacious
|
@@ -79,7 +79,6 @@ files:
|
|
79
79
|
- ".gitignore"
|
80
80
|
- Gemfile
|
81
81
|
- LICENSE
|
82
|
-
- LICENSE.txt
|
83
82
|
- README.md
|
84
83
|
- Rakefile
|
85
84
|
- bin/console
|
data/LICENSE.txt
DELETED
@@ -1,21 +0,0 @@
|
|
1
|
-
The MIT License (MIT)
|
2
|
-
|
3
|
-
Copyright (c) 2016 Bodacious
|
4
|
-
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
7
|
-
in the Software without restriction, including without limitation the rights
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
10
|
-
furnished to do so, subject to the following conditions:
|
11
|
-
|
12
|
-
The above copyright notice and this permission notice shall be included in
|
13
|
-
all copies or substantial portions of the Software.
|
14
|
-
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
-
THE SOFTWARE.
|