veda-apps 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 48b9e304b41df55e78085d3452905d5cab8e4f2f
4
- data.tar.gz: 101b908c141f75e6b044f6b7e8706d0f5b2f6fc7
3
+ metadata.gz: 0542c96e318ef577026b308353a4c3a5181ebfe4
4
+ data.tar.gz: 869a88dcd3f8d51596dde99b529590b045481ed9
5
5
  SHA512:
6
- metadata.gz: 2afbb8ca962ccc5e45d5adafddd94bae136189b2c16a7254f6b707013954f9445e2059c9fb2da337e52760bd6c385d5ff8ebc113aebd99e96d9284706d2e2642
7
- data.tar.gz: 20021ed6a0c6f8081fba59433f3d081e91c3a7d5ffbac4b1e7ac4dff755b38f06db6d95dc1e0b1e55c913ee8e45e2c9d3b2adcf30c8b4063b2ff1dd952f51da5
6
+ metadata.gz: 908db94bb23955b0554a91db4ed1dabdf23da376dc14ae18aca9a1a40c9b782b64a3b789bef72598bf2f494644a45ccd9a1b7e811bed70f65c4f0261b8e37d34
7
+ data.tar.gz: d887d4a00ef5dcf3688d11a25e27798901ffb880daa4a7c6392e4ebc1f3a3c20f03920188f49a2a61b20a0aded02aa23e72182bec8933eb97811623e3a1d2e9f
data/Gemfile.lock CHANGED
@@ -1,8 +1,9 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- veda-apps (0.0.3)
4
+ veda-apps (0.0.4)
5
5
  gli (= 2.17.1)
6
+ rest-client
6
7
 
7
8
  GEM
8
9
  remote: https://rubygems.org/
@@ -36,23 +37,25 @@ GEM
36
37
  cucumber-tag_expressions (1.1.1)
37
38
  cucumber-wire (0.0.1)
38
39
  diff-lcs (1.3)
39
- domain_name (0.5.20160128)
40
+ domain_name (0.5.20161129)
40
41
  unf (>= 0.0.5, < 1.0.0)
41
42
  ffi (1.9.18)
42
43
  gherkin (5.0.0)
43
44
  gli (2.17.1)
44
- http-cookie (1.0.2)
45
+ http-cookie (1.0.3)
45
46
  domain_name (~> 0.5)
46
- mime-types (2.99)
47
+ mime-types (3.1)
48
+ mime-types-data (~> 3.2015)
49
+ mime-types-data (3.2016.0521)
47
50
  multi_json (1.13.1)
48
51
  multi_test (0.1.2)
49
52
  netrc (0.11.0)
50
53
  rake (12.3.0)
51
54
  rdoc (6.0.1)
52
- rest-client (1.8.0)
55
+ rest-client (2.0.2)
53
56
  http-cookie (>= 1.0.2, < 2.0)
54
- mime-types (>= 1.16, < 3.0)
55
- netrc (~> 0.7)
57
+ mime-types (>= 1.16, < 4.0)
58
+ netrc (~> 0.8)
56
59
  rspec-expectations (3.7.0)
57
60
  diff-lcs (>= 1.2.0, < 2.0)
58
61
  rspec-support (~> 3.7.0)
@@ -69,7 +72,6 @@ DEPENDENCIES
69
72
  aruba
70
73
  rake
71
74
  rdoc
72
- rest-client
73
75
  veda-apps!
74
76
 
75
77
  BUNDLED WITH
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2018 shishir sapkota
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 all
13
+ 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 THE
21
+ SOFTWARE.
data/README.md CHANGED
@@ -1,62 +1,33 @@
1
- # Veda Ios modules generators
2
- ###### There are many times when we write same thing in different app. Like qr scanner, search etc. This is an attempt to automate the redundant task. Using command line we can generate specific task without writing all the codes. All codes generated can be customized according to your needs and are well tested. currently All codes are generated for Swift.
1
+ # veda-apps
2
+ ###### There are many times when we write same thing in different app. Like qr scanner,create models from api.. etc. This is an attempt to automate the redundant task. Using command line we can generate specific task without writing all the codes. All codes generated can be customized according to your needs and are well tested. currently All codes are generated for Swift.
3
3
 
4
4
 
5
- ### QR scanner
5
+ #### It is a collection of the common tools that we write over and over. And can create them with one line of code.
6
6
 
7
- **step 1:**
8
7
 
9
- generate qr module with command line.
8
+ examples:
10
9
 
11
- syntax: `veda generate --qr path_to_viewcontroller`
10
+ ```veda generate qr -f path_to_view_controller```
12
11
 
13
- example:
12
+ ```veda generate model input.json```
14
13
 
15
- `veda generate --qr /Users/shishirsapkota/Library/Autosave\ Information/qrTest/qrTest/ViewController.swift`
14
+ ### Wikis
15
+ #### QR scanner
16
16
 
17
- This will generate three files in the folder containing the viewcontroller.swift.
17
+ https://github.com/Iccr/VedaApp/wiki/QRScanner
18
18
 
19
- **step 2:**
20
19
 
21
- Add files to your xcode project.
20
+ #### Automatically Generate models from url:
22
21
 
23
- [Add files to your project like this](https://lh3.googleusercontent.com/yfMZKNaGzODzaQRtyGwUPJpRrhohbxheezgS04VRUeHvq3j9OgPrHnIDC_wNQTnSpv-S03OEPISFTEEVjl6WDmx3l-bMwmi0xNTYMgR-jgvHpy4sYRxBDUsl1SiNLPFJzDgz6ZUX9GaDQpwNLSqjXq5wFTE_O4TNgha_tHr1XI3eJu39wt5EX4HMWWKefzDKaOSac5OtEGUwZ_-LTju2J-3zMyD4q2tnbQ_uv853CCUWjqjcLOQ-6zsJYH9pJkf75yNsWV9We0-9kNKwCbPrEX6x-rdPux35dNTKmz5eC6czJo8ONgsmI2trfSxTN9ZCLIJ1YJP94RwdKlY-MtWpFdjZuqA3QGzB5rFIB98NkRqHx0hKk9UxP7QBYxeWl13O-Dd_RZJSNPn4gYXfav6SJbqvwd9HUv8uKCpCGAtn0QaK9YUZ6U9qHlBPTKfd74CmHB0aY-KQ4kc99a6h-SGMH72ARlkTe83__qgQyphwuPcU6rRn36ScNSxxwGkLZzzWwNkM8t7X1Fh7OGeN9WQ1E5oNxPzzwmJiP5S8e6ep6Rm2ISA7nb8qcHdyBLEj1QIcDAaIPYaxEuHfXVOMb2HtFXjrMVNP2BUVLzTPbWk=w340-h475-no)
22
+ https://github.com/Iccr/VedaApp/wiki/swift-model-generator
24
23
 
25
- Add three files generated.
26
24
 
27
- [Files after added.](https://lh3.googleusercontent.com/2i-K6a8L-snz5FEWeua32K3bAezDJhsHvXlLXK3sDTZsrXNYOSi7WAO14txD4aPbjI8XHs75vg5y6TCt_E1DUafbMD9-wxMAp1pvcVXt_zDJSvSJkxZmd5m0Xa8Ht-hj7PENwViavB_7QLzrLlrQ9vE4rWcvRYMYiVxO3QkdqSle_0xlm_mUwyzivZzGIazj2GD6nM88kMEBn6fCoImIxeGF8Q1C4c_aZKi_7PsBDIaKN-NS5Uz_PoVZVudt5XPIP-vhzSOmx4shZ_OajX8nctjVwVbpJdSXMCig2MSX3EAuWZlzmYxbO0viM3qmU9U75kmzgKWVsceB3Izqbv0Xh7CyHhvaS1wtEKvT48LKRzImZgsRbUqTitFwIspdJ18rfuXIodZwmquXcRu3K_YxGGXiMozdW2MnE_K780-IW6BDO786TK2ACbVLQmZY0RBxj2-AsTfwW0mhIK9gn6OLBpltF924au8U_TaTbPRVXt_2PRFCH7CspogICbP3qO8_s8_6BnS1lGv5fx_RpqmarZta6D8bsH31YGdqFKf84qHhvhlrA4f5yhtJOhe9l6v2uv8LngCf6Hz_c-bWXfsve4wBphwCdYk_StILGJg=w262-h102-no)
25
+ ###### feedback are welcomed
28
26
 
29
27
 
30
- **At the End of Your viewcontroller, extension where function to open the qr scanner is Automatically added.**
31
-
32
- ```swift
33
- extension ViewController {
34
- func scan() {
35
- self.openVedaQRScanner(source: self) { (viewcontroller, string) in
36
- let qrString = string
37
- print(qrString)
38
- }
39
- }
40
-
41
- func openVedaQRScanner(source: UIViewController, completion: @escaping (VedaQRScannerViewController, String)->()) {
42
- if let vc = UIStoryboard(name: "VedaQR", bundle: nil).instantiateInitialViewController() as? VedaQRScannerViewController {
43
- vc.onObtained = completion
44
- source.present(vc, animated: true, completion: nil)
45
- }
46
- }
47
- }
48
-
49
- ```
50
-
51
- **step3**:
52
-
53
- create an outlet and open qrscanner
54
-
55
- ```swift
56
- @IBAction func openQr(_ sender: UIButton) {
57
- self.scan()
58
- }
59
- ```
60
-
28
+ ###### Found a **bug**, please open an issue.
61
29
 
62
30
  Enjoy.
31
+
32
+ ###### License
33
+ MIT
data/lib/parser.rb CHANGED
@@ -139,8 +139,7 @@ class Parser
139
139
  REALMCLASS
140
140
 
141
141
  non_realm_funcs = <<-DEFAULT
142
- \t\tinit?(map: Map) {
143
- \t\t\t\tself.init()
142
+ \t\trequired init?(map: Map) {
144
143
  \t\t}
145
144
  DEFAULT
146
145
  # (map["friends"], ListTransform<User>())
@@ -162,10 +161,9 @@ DEFAULT
162
161
  mapping_literals += mapping_literal
163
162
  end
164
163
 
165
-
166
164
  class_model = <<-CLASS
167
165
  import ObjectMapper
168
- import RealmSwift
166
+ #{@realm? "import RealmSwift\nimport ObjectMapper_Realm" : ""}
169
167
 
170
168
  class #{class_name}:#{@realm? " Object," : ""} Mappable {
171
169
  #{attribute_literals}
data/lib/veda/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Veda
2
- VERSION = '0.0.4'
2
+ VERSION = '0.0.5'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: veda-apps
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shishir sapkota
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-01-23 00:00:00.000000000 Z
11
+ date: 2018-02-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -91,6 +91,7 @@ files:
91
91
  - ".DS_Store"
92
92
  - Gemfile
93
93
  - Gemfile.lock
94
+ - LICENSE
94
95
  - README.md
95
96
  - Rakefile
96
97
  - bin/veda