onotole 1.1.1 → 1.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +11 -0
- data/lib/onotole/adapters/heroku.rb +1 -1
- data/lib/onotole/add_user_gems/after_install_patch.rb +33 -25
- data/lib/onotole/add_user_gems/before_bundle_patch.rb +13 -0
- data/lib/onotole/add_user_gems/edit_menu_questions.rb +2 -0
- data/lib/onotole/default_frontend.rb +5 -0
- data/lib/onotole/default_scripts.rb +4 -0
- data/lib/onotole/generators/app_generator.rb +2 -4
- data/lib/onotole/helpers.rb +1 -1
- data/lib/onotole/version.rb +1 -1
- data/spec/fakes/bin/heroku +0 -0
- data/spec/fakes/bin/hub +0 -0
- data/templates/bin_deploy +0 -0
- data/templates/dotenv.erb +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c5ea838d334c7fd268cb2c0b1b3eb9b3e7ef83e8
|
4
|
+
data.tar.gz: f71a350cfcd7c2e5bebec9e29a5e3d141155e033
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 27f6cf1c85669532a15b33d18dd390eb66293b744d287b0c4590f29160a36a94e8f5e39331fed9d1b2873119c837edc3bc02fe342a3f424010aa79c03cbc5d3c
|
7
|
+
data.tar.gz: 07abb0223318ac2e99a68fa92f85d8b7e78704724f15002742cfa109c686cdfe3d509352ec133751796bfafb65d8e51b22aca09ed5c8d268d5be75588fe7f532
|
data/README.md
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
[![Code Climate](https://codeclimate.com/github/kvokka/onotole/badges/gpa.svg)](https://codeclimate.com/github/kvokka/onotole)
|
2
|
+
|
1
3
|
# Onotole
|
2
4
|
|
3
5
|
New Rails project wizard. Onotole will help!
|
@@ -99,8 +101,16 @@ creating elegant backends for website administration.
|
|
99
101
|
latin to cyrillic and vice versa
|
100
102
|
* [ckeditor](https://github.com/galetahub/ckeditor) CKEditor is a WYSIWYG text
|
101
103
|
editor designed to simplify web content creation.
|
104
|
+
* [axslx](https://github.com/randym/axlsx) Xlsx generation with charts, images,
|
105
|
+
automated column width, customizable styles and full schema validation.
|
102
106
|
* [axlsx_rails](https://github.com/straydogstudio/axlsx_rails) A Rails plug-in
|
103
107
|
to provide templates for the axlsx gem for providing Excel files format support
|
108
|
+
* [prawn](https://github.com/prawnpdf/prawn) Fast, Nimble PDF Writer for Ruby
|
109
|
+
http://prawnpdf.org
|
110
|
+
* [prawn-table](https://github.com/prawnpdf/prawn-table) Provides support for
|
111
|
+
tables in Prawn
|
112
|
+
* [fotoramajs](https://github.com/ai/fotoramajs) Fotorama JS gallery for Ruby
|
113
|
+
on Rails http://fotorama.io/
|
104
114
|
|
105
115
|
|
106
116
|
Mandatory installation gem list you will find in `Gemfile` section
|
@@ -240,6 +250,7 @@ Onotole also comes with:
|
|
240
250
|
* Added style flash messagaes for `bootstrap-sass` gem
|
241
251
|
* Auto add gem `devise_bootstrap_views` when `bootstrap-sass` and `devise`
|
242
252
|
selected for pretty view from the box
|
253
|
+
* Added autoload js and scss from `vendor/assets/javascripts` and `vendor/assets/stylesheets`
|
243
254
|
|
244
255
|
## Heroku
|
245
256
|
|
@@ -85,7 +85,7 @@ module Onotole
|
|
85
85
|
def set_heroku_serve_static_files
|
86
86
|
%w(staging production).each do |environment|
|
87
87
|
run_toolbelt_command(
|
88
|
-
|
88
|
+
"config:add #{app_name.upcase}_RAILS_SERVE_STATIC_FILES=true",
|
89
89
|
environment
|
90
90
|
)
|
91
91
|
end
|
@@ -2,31 +2,33 @@
|
|
2
2
|
module Onotole
|
3
3
|
module AfterInstallPatch
|
4
4
|
def post_init
|
5
|
-
install_queue = [
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
5
|
+
install_queue = [
|
6
|
+
:fotoramajs,
|
7
|
+
:devise,
|
8
|
+
:validates_timeliness,
|
9
|
+
:paper_trail,
|
10
|
+
:responders,
|
11
|
+
:typus,
|
12
|
+
:annotate,
|
13
|
+
:overcommit,
|
14
|
+
:activeadmin,
|
15
|
+
:active_admin_theme,
|
16
|
+
:acive_skin,
|
17
|
+
:flattened_active_admin,
|
18
|
+
:face_of_active_admin,
|
19
|
+
:active_admin_bootstrap,
|
20
|
+
:rails_admin,
|
21
|
+
:guard,
|
22
|
+
:guard_rubocop,
|
23
|
+
:bootstrap3_sass,
|
24
|
+
:bootstrap3,
|
25
|
+
:devise_bootstrap_views,
|
26
|
+
:active_admin_theme,
|
27
|
+
:font_awesome_sass,
|
28
|
+
:normalize,
|
29
|
+
:tinymce,
|
30
|
+
:rubocop,
|
31
|
+
:create_github_repo]
|
30
32
|
install_queue.each { |g| send "after_install_#{g}" if user_choose? g }
|
31
33
|
delete_comments
|
32
34
|
end
|
@@ -215,5 +217,11 @@ end
|
|
215
217
|
"\n#= require face_of_active_admin/base"
|
216
218
|
rails_generator 'face_of_active_admin:variables'
|
217
219
|
end
|
220
|
+
|
221
|
+
def after_install_fotoramajs
|
222
|
+
return unless user_choose? :fotoramajs
|
223
|
+
inject_into_file(AppBuilder.js_file, "\n//= require fotorama",
|
224
|
+
after: '//= require jquery_ujs')
|
225
|
+
end
|
218
226
|
end
|
219
227
|
end
|
@@ -253,8 +253,21 @@ module Onotole
|
|
253
253
|
inject_into_file('Gemfile', "\ngem 'axlsx_rails'", after: '# user_choice')
|
254
254
|
end
|
255
255
|
|
256
|
+
def add_axlsx_gem
|
257
|
+
inject_into_file('Gemfile', "\ngem 'axlsx'", after: '# user_choice')
|
258
|
+
end
|
259
|
+
|
256
260
|
def add_face_of_active_admin_gem
|
257
261
|
inject_into_file('Gemfile', "\ngem 'face_of_active_admin'", after: '# user_choice')
|
258
262
|
end
|
263
|
+
|
264
|
+
def add_prawn_gem
|
265
|
+
inject_into_file('Gemfile', "\ngem 'prawn'", after: '# user_choice')
|
266
|
+
inject_into_file('Gemfile', "\ngem 'prawn-table'", after: '# user_choice')
|
267
|
+
end
|
268
|
+
|
269
|
+
def add_fotoramajs_gem
|
270
|
+
inject_into_file('Gemfile', "\ngem 'fotoramajs'", after: '# user_choice')
|
271
|
+
end
|
259
272
|
end
|
260
273
|
end
|
@@ -102,6 +102,8 @@ module Onotole
|
|
102
102
|
validates_timeliness: 'Date and time validation plugin for ActiveModel and Rails',
|
103
103
|
font_awesome_sass: 'Font-Awesome Sass gem for use in Ruby/Rails projects',
|
104
104
|
ckeditor: 'CKEditor is a WYSIWYG text editor designed for web content creation.',
|
105
|
+
fotoramajs: 'Fotorama JS gallery for Rails http://fotorama.io/',
|
106
|
+
prawn: 'Prawn gem for PDF support vs prawn-table for easy tables',
|
105
107
|
axlsx_rails: 'XLS support, cyrillic support, good support at all'
|
106
108
|
}
|
107
109
|
multiple_choice('Write numbers of all preferred gems.', variants).each do |gem|
|
@@ -75,5 +75,10 @@ module Onotole
|
|
75
75
|
def create_shared_javascripts
|
76
76
|
copy_file '_javascript.html.erb', 'app/views/application/_javascript.html.erb'
|
77
77
|
end
|
78
|
+
|
79
|
+
def add_vendor_css_path
|
80
|
+
vendor_css_path = "\nRails.application.config.assets.paths += Dir[(Rails.root.join('vendor/assets/stylesheets'))]"
|
81
|
+
append_file 'config/initializers/assets.rb', vendor_css_path
|
82
|
+
end
|
78
83
|
end
|
79
84
|
end
|
@@ -192,5 +192,9 @@ end
|
|
192
192
|
config = "\n config.autoload_paths << Rails.root.join('app/support')\n"
|
193
193
|
inject_into_class 'config/application.rb', 'Application', config
|
194
194
|
end
|
195
|
+
|
196
|
+
def apply_vendorjs_folder
|
197
|
+
inject_into_file(AppBuilder.js_file, "//= require_tree ../../../vendor/assets/javascripts/.\n", before: '//= require_tree .')
|
198
|
+
end
|
195
199
|
end
|
196
200
|
end
|
@@ -175,6 +175,8 @@ module Onotole
|
|
175
175
|
build :setup_default_rake_task
|
176
176
|
build :configure_puma
|
177
177
|
build :set_up_forego
|
178
|
+
build :apply_vendorjs_folder
|
179
|
+
build :add_vendor_css_path
|
178
180
|
end
|
179
181
|
|
180
182
|
# def setup_stylesheets
|
@@ -296,10 +298,6 @@ module Onotole
|
|
296
298
|
build :clean_by_rubocop
|
297
299
|
end
|
298
300
|
|
299
|
-
def configure_support_path
|
300
|
-
build :configure_support_path
|
301
|
-
end
|
302
|
-
|
303
301
|
protected
|
304
302
|
|
305
303
|
def get_builder_class
|
data/lib/onotole/helpers.rb
CHANGED
@@ -54,7 +54,7 @@ module Onotole
|
|
54
54
|
end
|
55
55
|
|
56
56
|
def serve_static_files_line
|
57
|
-
"config.serve_static_files = ENV
|
57
|
+
"config.serve_static_files = ENV.fetch('#{app_name.upcase}_RAILS_SERVE_STATIC_FILES',false)\n"
|
58
58
|
end
|
59
59
|
|
60
60
|
def add_gems_from_args
|
data/lib/onotole/version.rb
CHANGED
data/spec/fakes/bin/heroku
CHANGED
File without changes
|
data/spec/fakes/bin/hub
CHANGED
File without changes
|
data/templates/bin_deploy
CHANGED
File without changes
|
data/templates/dotenv.erb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: onotole
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- kvokka
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2016-03-
|
12
|
+
date: 2016-03-17 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bundler
|