rgentpl 1.2.6 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (133) hide show
  1. checksums.yaml +5 -5
  2. data/.gitignore +0 -11
  3. data/.rspec +0 -1
  4. data/.ruby-version +1 -1
  5. data/.solargraph.yml +14 -0
  6. data/.standard.yml +13 -0
  7. data/.yardopts +0 -0
  8. data/Gemfile +2 -2
  9. data/Gemfile.lock +271 -0
  10. data/Guardfile +13 -41
  11. data/LICENSE.txt +0 -0
  12. data/README.md +2 -12
  13. data/Rakefile +7 -8
  14. data/bin/rgentpl +3 -3
  15. data/config/boot.rb +2 -2
  16. data/config/environment.rb +2 -2
  17. data/config/environments/development.rb +1 -1
  18. data/config/environments/production.rb +0 -0
  19. data/config/environments/test.rb +1 -1
  20. data/lib/rgentpl/boot/application.rb +0 -0
  21. data/lib/rgentpl/boot/initializer.rb +1 -1
  22. data/lib/rgentpl/command/base.rb +6 -6
  23. data/lib/rgentpl/command/generate.rb +11 -23
  24. data/lib/rgentpl/core/configuration.rb +5 -5
  25. data/lib/rgentpl/core_ext/string.rb +2 -2
  26. data/lib/rgentpl/exception/critical.rb +0 -0
  27. data/lib/rgentpl/version.rb +1 -1
  28. data/lib/rgentpl.rb +13 -15
  29. data/lib/tasks/rspec.rake +9 -0
  30. data/lib/tasks/rubycritic.rake +12 -0
  31. data/lib/tasks/standard.rake +5 -0
  32. data/lib/tasks/yard.rake +17 -0
  33. data/log/.gitignore +0 -0
  34. data/rgentpl.gemspec +44 -68
  35. data/spec/lib/rgentpl/boot/application_spec.rb +4 -6
  36. data/spec/lib/rgentpl/boot/initializer_spec.rb +8 -8
  37. data/spec/lib/rgentpl/command/base_spec.rb +8 -8
  38. data/spec/lib/rgentpl/command/generate_spec.rb +12 -12
  39. data/spec/lib/rgentpl/core/configuration_spec.rb +21 -22
  40. data/spec/lib/rgentpl/core_ext/string_spec.rb +7 -7
  41. data/spec/lib/rgentpl_spec.rb +10 -10
  42. data/spec/spec_helper.rb +12 -18
  43. data/spec/support/.gitkeep +0 -0
  44. data/src/%app_name%.gemspec.tt +29 -51
  45. data/src/.gitignore +0 -11
  46. data/src/.rspec +0 -1
  47. data/src/.ruby-version +1 -1
  48. data/src/.solargraph.yml +14 -0
  49. data/src/.standard.yml +13 -0
  50. data/src/.yardopts +0 -0
  51. data/src/Gemfile +2 -2
  52. data/src/Guardfile +13 -41
  53. data/src/LICENSE.txt +0 -0
  54. data/src/README.md.tt +3 -2
  55. data/src/Rakefile +7 -8
  56. data/src/config/boot.rb.tt +0 -0
  57. data/src/config/environment.rb.tt +1 -1
  58. data/src/config/environments/development.rb.tt +0 -0
  59. data/src/config/environments/production.rb +0 -0
  60. data/src/config/environments/test.rb +1 -1
  61. data/src/config/initializers/.gitignore +0 -0
  62. data/src/doc/.gitignore +0 -0
  63. data/src/lib/%app_name%/boot/application.rb.tt +0 -0
  64. data/src/lib/%app_name%/boot/initializer.rb.tt +0 -0
  65. data/src/lib/%app_name%/command/base.rb.tt +0 -0
  66. data/src/lib/%app_name%/core/configuration.rb.tt +0 -0
  67. data/src/lib/%app_name%/core_ext/string.rb.tt +0 -0
  68. data/src/lib/%app_name%/exception/critical.rb.tt +0 -0
  69. data/src/lib/%app_name%/version.rb.tt +0 -0
  70. data/src/lib/%app_name%.rb.tt +2 -4
  71. data/src/lib/tasks/rspec.rake +9 -0
  72. data/src/lib/tasks/rubycritic.rake +12 -0
  73. data/src/lib/tasks/standard.rake +5 -0
  74. data/src/lib/tasks/yard.rake +17 -0
  75. data/src/log/yard.log +0 -0
  76. data/src/spec/lib/%app_name%/boot/application_spec.rb.tt +2 -4
  77. data/src/spec/lib/%app_name%/boot/initializer_spec.rb.tt +1 -1
  78. data/src/spec/lib/%app_name%/command/base_spec.rb.tt +0 -0
  79. data/src/spec/lib/%app_name%/core/configuration_spec.rb.tt +6 -4
  80. data/src/spec/lib/%app_name%/core_ext/.gitignore +0 -0
  81. data/src/spec/lib/%app_name%/core_ext/string_spec.rb.tt +1 -1
  82. data/src/spec/lib/%app_name%/exception/.gitignore +0 -0
  83. data/src/spec/lib/%app_name%_spec.rb.tt +1 -1
  84. data/src/spec/spec_helper.rb +25 -0
  85. data/src/spec/support/.gitkeep +0 -0
  86. data/src/tmp/.gitkeep +0 -0
  87. data/tmp/.gitkeep +0 -0
  88. metadata +55 -377
  89. data/.cane +0 -7
  90. data/.document +0 -3
  91. data/.excellent.yml +0 -1
  92. data/.rspec-travis +0 -2
  93. data/.rubocop.yml +0 -32
  94. data/.ruby-gemset +0 -1
  95. data/.travis.yml +0 -17
  96. data/Capfile +0 -27
  97. data/ChangeLog.md +0 -141
  98. data/README.rdoc +0 -4
  99. data/ShortLog +0 -84
  100. data/config/deploy/production.rb +0 -9
  101. data/config/deploy/staging.rb +0 -9
  102. data/config/deploy.rb +0 -43
  103. data/lib/capistrano/tasks/copy_git.rake +0 -13
  104. data/src/.cane +0 -7
  105. data/src/.document +0 -3
  106. data/src/.excellent.yml +0 -1
  107. data/src/.rspec-travis +0 -2
  108. data/src/.rubocop.yml +0 -32
  109. data/src/.ruby-gemset.tt +0 -1
  110. data/src/.travis.yml +0 -17
  111. data/src/Capfile +0 -27
  112. data/src/ChangeLog.md +0 -0
  113. data/src/README.rdoc +0 -3
  114. data/src/ShortLog +0 -0
  115. data/src/config/deploy/production.rb +0 -9
  116. data/src/config/deploy/staging.rb +0 -9
  117. data/src/config/deploy.rb +0 -43
  118. data/src/lib/capistrano/tasks/copy_git.rake +0 -13
  119. data/src/spec/spec_helper.rb.tt +0 -29
  120. data/src/tasks/excellent.rake +0 -8
  121. data/src/tasks/quality.rake +0 -15
  122. data/src/tasks/rspec.rake +0 -9
  123. data/src/tasks/rubocop.rake +0 -10
  124. data/src/tasks/rubycritic.rake +0 -13
  125. data/src/tasks/sdoc.rake +0 -19
  126. data/src/tasks/yard.rake +0 -18
  127. data/tasks/excellent.rake +0 -8
  128. data/tasks/quality.rake +0 -15
  129. data/tasks/rspec.rake +0 -9
  130. data/tasks/rubocop.rake +0 -10
  131. data/tasks/rubycritic.rake +0 -13
  132. data/tasks/sdoc.rake +0 -19
  133. data/tasks/yard.rake +0 -18
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 535f76e3cddb3c1a5e899e7e5e3d4d16753dca97
4
- data.tar.gz: 115d5e3630d3458fc1eec7d3956b4cd4a27ba5e8
2
+ SHA256:
3
+ metadata.gz: 360226e536ef79219caa90d0de7b86720e9f57c5b41d77e4bae6496fd3a70d72
4
+ data.tar.gz: 6e69b256b7b03496708ad1d0252128b3a8049ab7904708b368aa7f7f06f2d142
5
5
  SHA512:
6
- metadata.gz: afcabed015a4bae5178fc24ab739642c82b01a57ed635665e70244fb8551bfdf276ecf8ec663ae117b12929334ffa3bed758b4993a94c0536236737bb4ac6b82
7
- data.tar.gz: 391ecf30d1282adb70a4eb85da8d8de4e62d773666b73b0dd0a27e11ee3df244cf35555e1018915c9296b423556991a708f2cb16df78b6bb0ad750bf071d5f4f
6
+ metadata.gz: c39bb736c65a0db48f936d13ff2a3112dd1e12a8758225d2f0806ee138c2fb4d8a2551bbce75ac583ea9125dc6bc6d8c0d3be5f93c4d2edc364047cfa7bca8f4
7
+ data.tar.gz: aa17d41808eea438e955ec624ddb6960c512f73a762095b3d8918fd6638e72e10f706c4402dbd60db670d22aa8d7d60a7d9e8a4646c86d51cc6658b53a0b7a7b
data/.gitignore CHANGED
@@ -8,7 +8,6 @@
8
8
  db/*.sqlite3
9
9
 
10
10
  # Ignore all logfiles and tempfiles.
11
- Gemfile.lock
12
11
  log/app.log
13
12
  log/development.log
14
13
  log/production.log
@@ -30,7 +29,6 @@ pkg
30
29
  gems
31
30
 
32
31
  # Documentation
33
- doc/rdoc
34
32
  doc/api
35
33
  doc/app
36
34
  .yardoc/*
@@ -47,7 +45,6 @@ cache
47
45
  vendor/cache
48
46
 
49
47
  # Testing
50
- capybara*
51
48
  specifications
52
49
  !spec/support/.gitkeep
53
50
  !src/%app_name%.gemspec.tt/spec/support/.gitkeep
@@ -69,9 +66,6 @@ vendor/extensions/**/spec/dummy
69
66
  # Backup
70
67
  *~
71
68
 
72
- # Capybara Bug
73
- capybara-*html
74
-
75
69
  # sass
76
70
  .sass-cache
77
71
  .sass-cache/*
@@ -80,17 +74,12 @@ capybara-*html
80
74
  .rvmrc
81
75
  .rvmrc.*
82
76
 
83
- # CTags
84
- .tags*
85
77
  .gemtags*
86
78
  gem-tags*
87
79
 
88
80
  # TODO (Plain Tasks in Sublime Text 2)
89
81
  *.TODO
90
82
 
91
- # Sublime project files
92
- *.sublime-*
93
-
94
83
  # Webrat log
95
84
  webrat.log
96
85
 
data/.rspec CHANGED
@@ -4,4 +4,3 @@
4
4
  --format documentation
5
5
  --format Nc
6
6
  --format Fuubar
7
- #--format NyanCatFormatter
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- ruby-2.2.1
1
+ 3.1.4
data/.solargraph.yml ADDED
@@ -0,0 +1,14 @@
1
+ ---
2
+ include:
3
+ - "**/*.rb"
4
+ exclude:
5
+ - spec/**/*
6
+ - vendor/**/*
7
+ - ".bundle/**/*"
8
+ require: []
9
+ domains: []
10
+ reporters:
11
+ - rubocop
12
+ - require_not_found
13
+ require_paths: []
14
+ max_files: 5000
data/.standard.yml ADDED
@@ -0,0 +1,13 @@
1
+ ---
2
+ fix: true
3
+ parallel: true
4
+ format: progress
5
+ ruby_version: 3.1.4
6
+
7
+ require:
8
+ - rubocop-rake
9
+ - rubocop-rspec
10
+
11
+ ignore:
12
+ - "db/schema.rb"
13
+ - "vendor/**/*"
data/.yardopts CHANGED
File without changes
data/Gemfile CHANGED
@@ -1,5 +1,5 @@
1
- source 'https://rubygems.org'
1
+ source "https://rubygems.org"
2
2
 
3
- ruby '2.2.1'
3
+ ruby "3.1.4"
4
4
 
5
5
  gemspec
data/Gemfile.lock ADDED
@@ -0,0 +1,271 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ rgentpl (1.2.6)
5
+ logger
6
+ rake
7
+ thor
8
+ virtus
9
+
10
+ GEM
11
+ remote: https://rubygems.org/
12
+ specs:
13
+ addressable (2.8.4)
14
+ public_suffix (>= 2.0.2, < 6.0)
15
+ ast (2.4.2)
16
+ awesome_print (1.9.2)
17
+ axiom-types (0.1.1)
18
+ descendants_tracker (~> 0.0.4)
19
+ ice_nine (~> 0.11.0)
20
+ thread_safe (~> 0.3, >= 0.3.1)
21
+ backport (1.2.0)
22
+ benchmark (0.2.1)
23
+ byebug (11.1.3)
24
+ coderay (1.1.3)
25
+ coercible (1.0.0)
26
+ descendants_tracker (~> 0.0.1)
27
+ colorize (0.8.1)
28
+ debug (1.7.2)
29
+ irb (>= 1.5.0)
30
+ reline (>= 0.3.1)
31
+ descendants_tracker (0.0.4)
32
+ thread_safe (~> 0.3, >= 0.3.1)
33
+ diff-lcs (1.5.0)
34
+ docile (1.4.0)
35
+ e2mmap (0.1.0)
36
+ equalizer (0.0.11)
37
+ erubi (1.12.0)
38
+ ffi (1.15.5)
39
+ flay (2.13.0)
40
+ erubi (~> 1.10)
41
+ path_expander (~> 1.0)
42
+ ruby_parser (~> 3.0)
43
+ sexp_processor (~> 4.0)
44
+ flog (4.6.6)
45
+ path_expander (~> 1.0)
46
+ ruby_parser (~> 3.1, > 3.1.0)
47
+ sexp_processor (~> 4.8)
48
+ formatador (1.1.0)
49
+ fuubar (2.5.1)
50
+ rspec-core (~> 3.0)
51
+ ruby-progressbar (~> 1.4)
52
+ guard (2.18.0)
53
+ formatador (>= 0.2.4)
54
+ listen (>= 2.7, < 4.0)
55
+ lumberjack (>= 1.0.12, < 2.0)
56
+ nenv (~> 0.1)
57
+ notiffany (~> 0.0)
58
+ pry (>= 0.13.0)
59
+ shellany (~> 0.0)
60
+ thor (>= 0.18.1)
61
+ guard-bundler (3.0.1)
62
+ bundler (>= 2.1, < 3)
63
+ guard (~> 2.2)
64
+ guard-compat (~> 1.1)
65
+ guard-compat (1.2.1)
66
+ guard-rspec (4.7.3)
67
+ guard (~> 2.1)
68
+ guard-compat (~> 1.1)
69
+ rspec (>= 2.99.0, < 4.0)
70
+ guard-rubycritic (2.9.3)
71
+ guard (~> 2.6)
72
+ rubycritic (>= 2.9.3)
73
+ guard-standardrb (0.2.2)
74
+ guard (>= 2.0.0)
75
+ guard-compat (~> 1.0)
76
+ standardrb
77
+ guard-yard (2.2.1)
78
+ guard (>= 1.1.0)
79
+ yard (>= 0.7.0)
80
+ ice_nine (0.11.2)
81
+ io-console (0.6.0)
82
+ irb (1.6.4)
83
+ reline (>= 0.3.0)
84
+ jaro_winkler (1.5.4)
85
+ kramdown (2.4.0)
86
+ rexml
87
+ kramdown-parser-gfm (1.1.0)
88
+ kramdown (~> 2.0)
89
+ kwalify (0.7.2)
90
+ launchy (2.5.2)
91
+ addressable (~> 2.8)
92
+ listen (3.8.0)
93
+ rb-fsevent (~> 0.10, >= 0.10.3)
94
+ rb-inotify (~> 0.9, >= 0.9.10)
95
+ logger (1.5.3)
96
+ lumberjack (1.2.8)
97
+ method_source (1.0.0)
98
+ msgpack (1.7.0)
99
+ multi_json (1.15.0)
100
+ nenv (0.3.0)
101
+ neovim (0.9.0)
102
+ msgpack (~> 1.1)
103
+ multi_json (~> 1.0)
104
+ nokogiri (1.14.3-arm64-darwin)
105
+ racc (~> 1.4)
106
+ notiffany (0.1.3)
107
+ nenv (~> 0.1)
108
+ shellany (~> 0.0)
109
+ parallel (1.22.1)
110
+ parser (3.2.2.0)
111
+ ast (~> 2.4.1)
112
+ path_expander (1.1.1)
113
+ pry (0.14.2)
114
+ coderay (~> 1.1)
115
+ method_source (~> 1.0)
116
+ pry-byebug (3.10.1)
117
+ byebug (~> 11.0)
118
+ pry (>= 0.13, < 0.15)
119
+ psych (5.1.0)
120
+ stringio
121
+ public_suffix (5.0.1)
122
+ racc (1.6.2)
123
+ rainbow (3.1.1)
124
+ rake (13.0.6)
125
+ rb-fsevent (0.11.2)
126
+ rb-inotify (0.10.1)
127
+ ffi (~> 1.0)
128
+ rdoc (6.5.0)
129
+ psych (>= 4.0.0)
130
+ redcarpet (3.6.0)
131
+ reek (6.1.4)
132
+ kwalify (~> 0.7.0)
133
+ parser (~> 3.2.0)
134
+ rainbow (>= 2.0, < 4.0)
135
+ regexp_parser (2.7.0)
136
+ reline (0.3.3)
137
+ io-console (~> 0.5)
138
+ reverse_markdown (2.1.1)
139
+ nokogiri
140
+ rexml (3.2.5)
141
+ rspec (3.12.0)
142
+ rspec-core (~> 3.12.0)
143
+ rspec-expectations (~> 3.12.0)
144
+ rspec-mocks (~> 3.12.0)
145
+ rspec-core (3.12.1)
146
+ rspec-support (~> 3.12.0)
147
+ rspec-expectations (3.12.2)
148
+ diff-lcs (>= 1.2.0, < 2.0)
149
+ rspec-support (~> 3.12.0)
150
+ rspec-mocks (3.12.5)
151
+ diff-lcs (>= 1.2.0, < 2.0)
152
+ rspec-support (~> 3.12.0)
153
+ rspec-nc (0.3.0)
154
+ rspec (>= 3)
155
+ terminal-notifier (>= 1.4)
156
+ rspec-support (3.12.0)
157
+ rubocop (1.23.0)
158
+ parallel (~> 1.10)
159
+ parser (>= 3.0.0.0)
160
+ rainbow (>= 2.2.2, < 4.0)
161
+ regexp_parser (>= 1.8, < 3.0)
162
+ rexml
163
+ rubocop-ast (>= 1.12.0, < 2.0)
164
+ ruby-progressbar (~> 1.7)
165
+ unicode-display_width (>= 1.4.0, < 3.0)
166
+ rubocop-ast (1.28.0)
167
+ parser (>= 3.2.1.0)
168
+ rubocop-performance (1.12.0)
169
+ rubocop (>= 1.7.0, < 2.0)
170
+ rubocop-ast (>= 0.4.0)
171
+ rubocop-rake (0.6.0)
172
+ rubocop (~> 1.0)
173
+ rubocop-rspec (2.11.1)
174
+ rubocop (~> 1.19)
175
+ ruby-progressbar (1.13.0)
176
+ ruby_parser (3.20.0)
177
+ sexp_processor (~> 4.16)
178
+ rubycritic (4.7.0)
179
+ flay (~> 2.8)
180
+ flog (~> 4.4)
181
+ launchy (>= 2.0.0)
182
+ parser (>= 2.6.0)
183
+ rainbow (~> 3.0)
184
+ reek (~> 6.0, < 7.0)
185
+ ruby_parser (~> 3.8)
186
+ simplecov (>= 0.17.0)
187
+ tty-which (~> 0.4.0)
188
+ virtus (~> 1.0)
189
+ sdoc (2.6.1)
190
+ rdoc (>= 5.0)
191
+ sexp_processor (4.16.1)
192
+ shellany (0.0.1)
193
+ simplecov (0.22.0)
194
+ docile (~> 1.1)
195
+ simplecov-html (~> 0.11)
196
+ simplecov_json_formatter (~> 0.1)
197
+ simplecov-html (0.12.3)
198
+ simplecov_json_formatter (0.1.4)
199
+ solargraph (0.48.0)
200
+ backport (~> 1.2)
201
+ benchmark
202
+ bundler (>= 1.17.2)
203
+ diff-lcs (~> 1.4)
204
+ e2mmap
205
+ jaro_winkler (~> 1.5)
206
+ kramdown (~> 2.3)
207
+ kramdown-parser-gfm (~> 1.1)
208
+ parser (~> 3.0)
209
+ reverse_markdown (>= 1.0.5, < 3)
210
+ rubocop (>= 0.52)
211
+ thor (~> 1.0)
212
+ tilt (~> 2.0)
213
+ yard (~> 0.9, >= 0.9.24)
214
+ standard (1.5.0)
215
+ rubocop (= 1.23.0)
216
+ rubocop-performance (= 1.12.0)
217
+ standardrb (1.0.1)
218
+ standard
219
+ stringio (3.0.6)
220
+ terminal-notifier (2.0.0)
221
+ thor (1.2.1)
222
+ thread_safe (0.3.6)
223
+ tilt (2.1.0)
224
+ tty-which (0.4.2)
225
+ unicode-display_width (2.4.2)
226
+ virtus (1.0.5)
227
+ axiom-types (~> 0.1)
228
+ coercible (~> 1.0)
229
+ descendants_tracker (~> 0.0, >= 0.0.3)
230
+ equalizer (~> 0.0, >= 0.0.9)
231
+ webrick (1.8.1)
232
+ yard (0.9.34)
233
+
234
+ PLATFORMS
235
+ arm64-darwin-21
236
+
237
+ DEPENDENCIES
238
+ awesome_print
239
+ bundler
240
+ byebug
241
+ colorize
242
+ debug (>= 1.0.0)
243
+ fuubar
244
+ guard
245
+ guard-bundler
246
+ guard-rspec
247
+ guard-rubycritic
248
+ guard-standardrb
249
+ guard-yard
250
+ neovim
251
+ pry
252
+ pry-byebug
253
+ redcarpet
254
+ rgentpl!
255
+ rspec
256
+ rspec-nc
257
+ rubocop-rake
258
+ rubocop-rspec
259
+ rubycritic
260
+ sdoc
261
+ simplecov
262
+ solargraph
263
+ standard (= 1.5.0)
264
+ webrick
265
+ yard
266
+
267
+ RUBY VERSION
268
+ ruby 3.1.4p223
269
+
270
+ BUNDLED WITH
271
+ 2.3.26
data/Guardfile CHANGED
@@ -1,53 +1,25 @@
1
- notification :growl
2
-
3
- # Bundler
4
1
  guard :bundler do
5
- watch('Gemfile')
2
+ watch("Gemfile")
6
3
  end
7
4
 
8
- # Yard (documentation)
9
5
  guard :yard,
10
- stdout: 'log/yard.log' do
11
-
6
+ stdout: "log/yard.log" do
12
7
  watch(%r{lib/.+\.rb})
13
- watch(%r{vendor/.+\.rb})
14
- end
15
-
16
- # Cane (code metrics)
17
- guard :cane do
18
- watch(%r{^(.+)\.rb$})
19
8
  end
20
9
 
21
- # Rubycritic (code metrics)
22
- guard 'rubycritic' do
10
+ guard :rubycritic do
23
11
  watch(%r{^lib/(.+)\.rb$})
24
12
  end
25
13
 
26
- group :red_green_refactor, halt_on_fail: true do
27
- # RSpec
28
- guard :rspec,
29
- cmd: 'rspec -f html -o ./tmp/spec_results.html --fail-fast',
30
- launchy: false,
31
- all_on_start: false,
32
- failed_mode: :focus,
33
- notification: true do
34
- watch(%r{^spec/.+_spec\.rb$})
35
- watch(%r{^lib/(.+)\.rb$}) { |m| "spec/lib/#{m[1]}_spec.rb" }
36
- watch('spec/spec_helper.rb') { "spec" }
37
-
38
- # Turnip features and steps
39
- watch(%r{^spec/acceptance/(.+)\.feature$})
40
- watch(%r{^spec/acceptance/steps/(.+)_steps\.rb$}) { |m| Dir[File.join("**/#{m[1]}.feature")][0] || 'spec/acceptance' }
41
- end
42
-
43
- # Rubocop (code style checker)
44
- guard :rubocop,
45
- all_on_start: false,
46
- hide_stdout: false,
47
- cli: ['--out tmp/rubocop_results.html', '--format html', '--rails'],
48
- notification: true do
14
+ guard :standardrb, fix: false, all_on_start: false, progress: false do
15
+ watch(/.+\.rb$/)
16
+ end
49
17
 
50
- watch(%r{.+\.rb$})
51
- watch(%r{(?:.+/)?\.rubocop\.yml$}) { |m| File.dirname(m[0]) }
52
- end
18
+ guard :rspec,
19
+ cmd: "bundle exec rspec --fail-fast",
20
+ all_on_start: false,
21
+ failed_mode: :focus do
22
+ watch(%r{^spec/.+_spec\.rb$})
23
+ watch(%r{^lib/(.+)\.rb$}) { |m| "spec/lib/#{m[1]}_spec.rb" }
24
+ watch("spec/spec_helper.rb") { "spec" }
53
25
  end
data/LICENSE.txt CHANGED
File without changes
data/README.md CHANGED
@@ -3,7 +3,7 @@ Introduction
3
3
 
4
4
  **rgentpl** is a Ruby library to generate a custom skeleton app.
5
5
 
6
- [![Build Status](https://travis-ci.org/jatap/rgentpl.png)](https://travis-ci.org/jatap/rgentpl)
6
+ [![Ruby Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://github.com/testdouble/standard)
7
7
 
8
8
  It's based on a great toolkit for building powerful command-line interfaces, [Thor](https://github.com/erikhuda/thor), and main goal is cover some basic good practices.
9
9
 
@@ -25,6 +25,7 @@ Application file structure (similar to generated).
25
25
  api/
26
26
 
27
27
  lib/
28
+ tasks/
28
29
  rgentpl/
29
30
  boot/
30
31
  command/
@@ -40,8 +41,6 @@ Application file structure (similar to generated).
40
41
 
41
42
  spec/
42
43
 
43
- tasks/
44
-
45
44
  tmp/
46
45
 
47
46
 
@@ -78,21 +77,12 @@ Generate app updating root path.
78
77
 
79
78
  $ rgentpl generate my_app -p /root/path/to/app
80
79
 
81
- Generate app updating root path and ctags binary path.
82
-
83
- > $ which ctags
84
-
85
- $ rgentpl generate my_app -p /root/path/to/app -t /path/to/ctags
86
-
87
80
  ### Options:
88
81
 
89
82
  * **-p** _root path_
90
83
 
91
84
  > Default value: /tmp
92
85
 
93
- * **-t** _ctags binary path_
94
-
95
- > Default value: /usr/local/bin/ctags
96
86
 
97
87
  ### Environments:
98
88
 
data/Rakefile CHANGED
@@ -1,13 +1,12 @@
1
- require File.expand_path('../config/environment', __FILE__)
1
+ require File.expand_path("../config/environment", __FILE__)
2
2
 
3
- require 'rubygems'
3
+ require "rubygems"
4
4
 
5
- # Bundler
6
5
  begin
7
- require 'bundler'
6
+ require "bundler"
8
7
  rescue LoadError => e
9
8
  warn e.message
10
- warn 'Run `gem install bundler` to install Bundler.'
9
+ warn "Run `gem install bundler` to install Bundler."
11
10
  exit false
12
11
  end
13
12
 
@@ -15,12 +14,12 @@ begin
15
14
  Bundler.setup(:development)
16
15
  rescue Bundler::BundlerError => e
17
16
  warn e.message
18
- warn 'Run `bundle install` to install missing gems.'
17
+ warn "Run `bundle install` to install missing gems."
19
18
  exit e.status_code
20
19
  end
21
20
 
22
21
  # Main
23
- require 'rake'
22
+ require "rake"
24
23
 
25
24
  # Custom tasks
26
- Dir[File.join(File.dirname(__FILE__), 'tasks/*.rake')].each { |rake| load rake }
25
+ Dir[File.join(File.dirname(__FILE__), "lib/tasks/*.rake")].each { |rake| load rake }
data/bin/rgentpl CHANGED
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
- require 'rubygems'
4
- require 'bundler/setup'
3
+ require "rubygems"
4
+ require "bundler/setup"
5
5
 
6
- require File.expand_path('../../config/environment', __FILE__)
6
+ require File.expand_path("../config/environment", __dir__)
7
7
 
8
8
  # Runner
9
9
  Rgentpl::Application.exec
data/config/boot.rb CHANGED
@@ -1,4 +1,4 @@
1
- TEMPLATE_ROOT = "#{File.expand_path(File.dirname(__FILE__) + "/..")}" unless defined?( TEMPLATE_ROOT )
1
+ TEMPLATE_ROOT = File.expand_path(File.dirname(__FILE__) + "/..").to_s unless defined?(TEMPLATE_ROOT)
2
2
 
3
3
  # Rgentpl
4
4
  #
@@ -19,7 +19,7 @@ module Rgentpl
19
19
  #
20
20
  # @return [void]
21
21
  def run
22
- require_relative '../lib/rgentpl' unless defined?(Rgentpl.env)
22
+ require_relative "../lib/rgentpl" unless defined?(Rgentpl.env)
23
23
  end
24
24
  end
25
25
  end
@@ -1,8 +1,8 @@
1
1
  # Environment
2
- TEMPLATE_ENV ||= ENV['TEMPLATE_ENV'] ||= 'development'
2
+ ENV["TEMPLATE_ENV"] ||= "development"
3
3
 
4
4
  # Boot up
5
- require File.join(File.dirname(__FILE__), 'boot')
5
+ require File.join(File.dirname(__FILE__), "boot")
6
6
 
7
7
  # Load extra tasks (load current environment)
8
8
  Rgentpl::Initializer.build
@@ -1,3 +1,3 @@
1
1
  Rgentpl.configure do |config|
2
- #config.active = false
2
+ # config.active = false
3
3
  end
File without changes
@@ -1 +1 @@
1
- require 'pry'
1
+ require "pry"
File without changes
@@ -15,7 +15,7 @@ module Rgentpl
15
15
  require_relative "../../../config/environments/#{Rgentpl.env}.rb"
16
16
 
17
17
  Dir[File.expand_path(File.join(File.dirname(__FILE__),
18
- '../../../config/initializers/*.rb'))]
18
+ "../../../config/initializers/*.rb"))]
19
19
  .each do |file|
20
20
  require_relative file
21
21
  end
@@ -8,10 +8,10 @@ module Rgentpl
8
8
  #
9
9
  # General command
10
10
  class Base < Thor
11
- package_name 'Rgentpl'
12
- map '-v' => :version
11
+ package_name "Rgentpl"
12
+ map "-v" => :version
13
13
 
14
- desc 'version, -v', 'Show Ruby Generator Template version.'
14
+ desc "version, -v", "Show Ruby Generator Template version."
15
15
  # @return [String] the test message
16
16
  def version
17
17
  say "Rgentpl version #{Rgentpl::VERSION}", :yellow
@@ -19,9 +19,9 @@ module Rgentpl
19
19
 
20
20
  # Add generate group command
21
21
  register(Rgentpl::Command::Generate,
22
- 'generate',
23
- 'generate APP_NAME [-p|--app_path APP_PATH] [-t|--ctags CTAGS]',
24
- 'Generate application')
22
+ "generate",
23
+ "generate APP_NAME [-p|--app_path APP_PATH]",
24
+ "Generate application")
25
25
  end
26
26
  end
27
27
  end