orats 5.2.2 → 5.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +4 -1
- data/CHANGELOG.md +4 -0
- data/README.md +1 -1
- data/lib/orats/templates/base/.env.example +6 -3
- data/lib/orats/templates/base/.rubocop.yml +4 -1
- data/lib/orats/templates/base/Gemfile +2 -2
- data/lib/orats/templates/base/bin/yarn +5 -7
- data/lib/orats/templates/base/config/application.rb +5 -2
- data/lib/orats/util.rb +5 -5
- data/lib/orats/version.rb +1 -1
- metadata +3 -4
- data/lib/orats/templates/base/config/initializers/timeout.rb +0 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 64a096396a9e4f70fcce79a5a6e4e789c287ea6d070597f46859029a28cb5d8c
|
4
|
+
data.tar.gz: b1b453d939fcc89cb0f275e2772f8ffa055b0457a890cc85c8d65a07a3acb3d2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 232c868c77dfdf4815804129c53c0b660d0fe438c31b47848c0f6fe91aed320d6618793ecee65018c849f85e7bc6314fb0185935f9255fc7d657486e22fc629c
|
7
|
+
data.tar.gz: a2d35ebf42671c9358ac36760a608eed116eba504f9ddc1c77bec062fb004fdec148cf988f52e132587019b3d4676edc90820a5ad640bae529b7cc8b1e92f9c9
|
data/.rubocop.yml
CHANGED
@@ -1,10 +1,13 @@
|
|
1
1
|
AllCops:
|
2
|
-
TargetRubyVersion: 2.
|
2
|
+
TargetRubyVersion: 2.5
|
3
3
|
|
4
4
|
Documentation:
|
5
5
|
# Skips checking to make sure top level modules / classes have a comment.
|
6
6
|
Enabled: false
|
7
7
|
|
8
|
+
Style/FrozenStringLiteralComment:
|
9
|
+
Enabled: false
|
10
|
+
|
8
11
|
Style/PercentLiteralDelimiters:
|
9
12
|
PreferredDelimiters:
|
10
13
|
default: ()
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
[![Gem Version](https://badge.fury.io/rb/orats.
|
1
|
+
[![Gem Version](https://badge.fury.io/rb/orats.svg)](http://badge.fury.io/rb/orats) [![Build Status](https://secure.travis-ci.org/nickjj/orats.svg)](http://travis-ci.org/nickjj/orats)
|
2
2
|
|
3
3
|
## What is orats?
|
4
4
|
|
@@ -29,7 +29,7 @@ WEB_CONCURRENCY=1
|
|
29
29
|
# Feel free to modify this value to fit the needs of your project, but if you
|
30
30
|
# have any request that takes more than 5 seconds you probably need to re-think
|
31
31
|
# what you are doing 99.99% of the time.
|
32
|
-
|
32
|
+
RACK_TIMEOUT_SERVICE_TIMEOUT=5
|
33
33
|
|
34
34
|
# Required by the Postgres Docker image. This sets up the initial database when
|
35
35
|
# you first run it.
|
@@ -40,8 +40,11 @@ POSTGRES_PASSWORD=yourpassword
|
|
40
40
|
# such as: orats_base_development or orats_base_production.
|
41
41
|
DATABASE_URL=postgresql://orats_base:yourpassword@postgres:5432/orats_base?encoding=utf8&pool=5&timeout=5000
|
42
42
|
|
43
|
-
# The full Redis URL for the Redis cache.
|
44
|
-
REDIS_CACHE_URL=redis://:yourpassword@redis:6379/0
|
43
|
+
# The full Redis URL for the Redis cache.
|
44
|
+
REDIS_CACHE_URL=redis://:yourpassword@redis:6379/0
|
45
|
+
|
46
|
+
# The namespace used by the Redis cache.
|
47
|
+
REDIS_CACHE_NAMESPACE=cache
|
45
48
|
|
46
49
|
# Action mailer (e-mail) settings.
|
47
50
|
# You will need to enable less secure apps in your Google account if you plan
|
@@ -1,5 +1,5 @@
|
|
1
1
|
AllCops:
|
2
|
-
TargetRubyVersion: 2.
|
2
|
+
TargetRubyVersion: 2.5
|
3
3
|
|
4
4
|
Exclude:
|
5
5
|
- 'db/**/*'
|
@@ -10,6 +10,9 @@ Documentation:
|
|
10
10
|
# Skips checking to make sure top level modules / classes have a comment.
|
11
11
|
Enabled: false
|
12
12
|
|
13
|
+
Style/FrozenStringLiteralComment:
|
14
|
+
Enabled: false
|
15
|
+
|
13
16
|
Style/ClassAndModuleChildren:
|
14
17
|
# Skips checking the style of children definitions at classes and modules.
|
15
18
|
#
|
@@ -12,7 +12,7 @@ gem 'rails', '~> 5.2.0'
|
|
12
12
|
gem 'puma', '~> 3.11'
|
13
13
|
|
14
14
|
# Use Rack Timeout. Read more: https://github.com/heroku/rack-timeout
|
15
|
-
gem 'rack-timeout', '~> 0.
|
15
|
+
gem 'rack-timeout', '~> 0.5'
|
16
16
|
|
17
17
|
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
|
18
18
|
gem 'jbuilder', '~> 2.5'
|
@@ -21,7 +21,7 @@ gem 'jbuilder', '~> 2.5'
|
|
21
21
|
gem 'pg', '~> 1.0'
|
22
22
|
|
23
23
|
# Use Redis Rails to set up a Redis backed Cache and / or Session
|
24
|
-
gem 'redis
|
24
|
+
gem 'redis', '~> 4.0'
|
25
25
|
|
26
26
|
# Use Sidekiq as a background job processor through Active Job
|
27
27
|
gem 'sidekiq', '~> 5.1'
|
@@ -1,11 +1,9 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
2
|
APP_ROOT = File.expand_path('..', __dir__)
|
3
3
|
Dir.chdir(APP_ROOT) do
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
exit 1
|
10
|
-
end
|
4
|
+
exec 'yarnpkg', *ARGV
|
5
|
+
rescue Errno::ENOENT
|
6
|
+
warn 'Yarn executable was not detected in the system.'
|
7
|
+
warn 'Download Yarn at https://yarnpkg.com/en/docs/install'
|
8
|
+
exit 1
|
11
9
|
end
|
@@ -46,7 +46,10 @@ module OratsBase
|
|
46
46
|
}
|
47
47
|
|
48
48
|
# Set Redis as the back-end for the cache.
|
49
|
-
config.cache_store = :
|
49
|
+
config.cache_store = :redis_cache_store, {
|
50
|
+
url: ENV['REDIS_CACHE_URL'],
|
51
|
+
namespace: ENV['REDIS_CACHE_NAMESPACE']
|
52
|
+
}
|
50
53
|
|
51
54
|
# Set Sidekiq as the back-end for Active Job.
|
52
55
|
config.active_job.queue_adapter = :sidekiq
|
@@ -65,7 +68,7 @@ end
|
|
65
68
|
|
66
69
|
# Show in-line form errors.
|
67
70
|
ActionView::Base.field_error_proc = proc do |html_tag, instance|
|
68
|
-
if
|
71
|
+
if /\<label/.match?(html_tag)
|
69
72
|
html_tag
|
70
73
|
else
|
71
74
|
errors = Array(instance.error_message).join(',')
|
data/lib/orats/util.rb
CHANGED
@@ -1,11 +1,11 @@
|
|
1
1
|
class Util
|
2
2
|
def self.underscore(term)
|
3
3
|
# taken from ActiveSupport
|
4
|
-
term.gsub
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
4
|
+
term.gsub(/::/, '/')
|
5
|
+
.gsub(/([A-Z]+)([A-Z][a-z])/, '\1_\2')
|
6
|
+
.gsub(/([a-z\d])([A-Z])/, '\1_\2')
|
7
|
+
.tr('-', '_')
|
8
|
+
.downcase
|
9
9
|
end
|
10
10
|
|
11
11
|
def self.classify(term)
|
data/lib/orats/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: orats
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.2.
|
4
|
+
version: 5.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nick Janetakis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-09-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|
@@ -164,7 +164,6 @@ files:
|
|
164
164
|
- lib/orats/templates/base/config/initializers/mime_types.rb
|
165
165
|
- lib/orats/templates/base/config/initializers/session_store.rb
|
166
166
|
- lib/orats/templates/base/config/initializers/sidekiq.rb
|
167
|
-
- lib/orats/templates/base/config/initializers/timeout.rb
|
168
167
|
- lib/orats/templates/base/config/initializers/wrap_parameters.rb
|
169
168
|
- lib/orats/templates/base/config/locales/en.yml
|
170
169
|
- lib/orats/templates/base/config/puma.rb
|
@@ -225,7 +224,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
225
224
|
version: '0'
|
226
225
|
requirements: []
|
227
226
|
rubyforge_project:
|
228
|
-
rubygems_version: 2.7.
|
227
|
+
rubygems_version: 2.7.6
|
229
228
|
signing_key:
|
230
229
|
specification_version: 4
|
231
230
|
summary: Opinionated rails application templates.
|
@@ -1 +0,0 @@
|
|
1
|
-
Rack::Timeout.timeout = ENV.fetch('REQUEST_TIMEOUT') { 5 }.to_i
|