sitepress-server 3.0.1 → 3.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/sitepress/server.rb +18 -7
- data/rails/app/controllers/site_controller.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 30f4e23fb8f70825308e4df34833298c6775b631042446ee5410900df9039435
|
4
|
+
data.tar.gz: 6f82fb4453d914e51c91a8b8a4c9e61aa7dc6b55e37f06a7c5a1bd1e3fcca05b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6bd62f362ead356633a072debdaf2695ec488bb7d51748eda7c8442ab1315a4b27e9c45f298cec9a36f95fb46fb1a8a79586a5d870e6056ed59da1a0a318cd19
|
7
|
+
data.tar.gz: 941ea02ff27b2c890c0893dd02a3e83d9736cefaf200c0eec10d62a2c2acb0640e7a20e8c7b22d66497a33b5b70eaac17df41db8f8cbf5a206119a4302acbb1d
|
data/lib/sitepress/server.rb
CHANGED
@@ -12,21 +12,32 @@ module Sitepress
|
|
12
12
|
# Control whether or not to display friendly error reporting messages
|
13
13
|
# in Sitepress. The development server turns this on an handles exception,
|
14
14
|
# while the compile and other environments would likely have this disabled.
|
15
|
-
config.
|
15
|
+
config.enable_site_error_reporting = false
|
16
16
|
|
17
17
|
# When in a development environment, we'll want to reload the site between
|
18
18
|
# requests so we can see the latest changes; otherwise, load the site once
|
19
19
|
# and we're done.
|
20
20
|
config.enable_site_reloading = false
|
21
21
|
|
22
|
-
#
|
23
|
-
|
22
|
+
# Default to a development environment type of configuration, which would reload the site.
|
23
|
+
# This gets reset later depending on a preference in the `before_initialize` callback.
|
24
|
+
config.eager_load = true
|
25
|
+
config.cache_classes = true
|
26
|
+
|
27
|
+
config.before_initialize do
|
28
|
+
# Eager load classes, content, etc. to boost performance when site reloading is disabled.
|
29
|
+
config.eager_load = !config.enable_site_reloading
|
24
30
|
|
25
|
-
|
26
|
-
|
27
|
-
|
31
|
+
# Cache classes for speed in production environments when site reloading is disabled.
|
32
|
+
config.cache_classes = !config.enable_site_reloading
|
33
|
+
end
|
34
|
+
|
35
|
+
# Path that points the the Sitepress UI rails app; which displays routes, error messages.
|
36
|
+
# etc. to the user if `enable_site_error_reporting` is enabled.
|
37
|
+
config.root = File.join(File.dirname(__FILE__), "../../rails")
|
28
38
|
|
29
|
-
|
39
|
+
# Rails won't start without this.
|
40
|
+
config.secret_key_base = SecureRandom.uuid
|
30
41
|
|
31
42
|
# Setup routes. The `constraints` key is set to `nil` so the `SiteController` can
|
32
43
|
# treat a page not being found as an exception, which it then handles. If the constraint
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sitepress-server
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.
|
4
|
+
version: 3.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brad Gessler
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-08-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rack-test
|
@@ -30,14 +30,14 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - '='
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 3.
|
33
|
+
version: 3.1.1
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - '='
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 3.
|
40
|
+
version: 3.1.1
|
41
41
|
description:
|
42
42
|
email:
|
43
43
|
- bradgessler@gmail.com
|