solid_cache 0.5.1 → 0.5.2

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
  SHA256:
3
- metadata.gz: 1045c342c381976b1af701309a06bcfc3334afb1e7f2b83e39f1064718fefeb5
4
- data.tar.gz: 59a6672e613a99b4bcf3d9c4215bd1d80a1bb2bd1ffcda3a4c5a0ac00d51bade
3
+ metadata.gz: 38d726f71df6fa627bc13b9ac25e8f9dcced7ac7069363457dbf1c74ee792d77
4
+ data.tar.gz: eae5c7042ce2e8f9b4d4eab807d5d95b44a5c7a00cc2714e16f3b684944035f2
5
5
  SHA512:
6
- metadata.gz: a55f8ce342e3b205ba5b37230328199adb194ec138eb78a27a6a1458c257377e9bf4d36db82bccaba7da3c345d92b25f2f3ae3d5f1da3296b4dbc75fdac69000
7
- data.tar.gz: 270d176c9271089141fe72e6464f5cfb09f6dd052636831a63cd862eb0fc694ad3c210d4dacc70becd34371c1710e27b0d316068964ee45729d1adc75a184ad3
6
+ metadata.gz: cf0cbafbd6f2d2da4787e3432d0e8c3ed3c79ac7e4bf2f66f9ddcd4e1bfd475451366acc8dcafd5dccac8daebbbf7c98f95c7684b29f3a1a182f9740ee2f48e6
7
+ data.tar.gz: '02360932ccf77f3e32c5d90cf086cc8c5d029f22384d7517f187aae6c541439d960f4072534fd646a1def164c62d4362d2c4162b6f6b7b4088b448a397da2c4f'
@@ -1,6 +1,8 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class SolidCache::InstallGenerator < Rails::Generators::Base
4
+ source_root File.expand_path("templates", __dir__)
5
+
4
6
  class_option :skip_migrations, type: :boolean, default: nil,
5
7
  desc: "Skip migrations"
6
8
 
@@ -12,6 +14,10 @@ class SolidCache::InstallGenerator < Rails::Generators::Base
12
14
  end
13
15
  end
14
16
 
17
+ def create_config_solid_cache_yml
18
+ template "config/solid_cache.yml"
19
+ end
20
+
15
21
  def create_migrations
16
22
  unless options[:skip_migrations]
17
23
  rails_command "railties:install:migrations FROM=solid_cache", inline: true
@@ -0,0 +1,15 @@
1
+ default: &default
2
+ database: <%%= Rails.env %>
3
+ store_options:
4
+ max_age: <%%= 1.week.to_i %>
5
+ max_size: <%%= 256.megabytes %>
6
+ namespace: <%%= Rails.env %>
7
+
8
+ development:
9
+ <<: *default
10
+
11
+ test:
12
+ <<: *default
13
+
14
+ production:
15
+ <<: *default
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SolidCache
4
- VERSION = "0.5.1"
4
+ VERSION = "0.5.2"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: solid_cache
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Donal McBreen
@@ -104,6 +104,7 @@ files:
104
104
  - lib/active_support/cache/solid_cache_store.rb
105
105
  - lib/generators/solid_cache/install/USAGE
106
106
  - lib/generators/solid_cache/install/install_generator.rb
107
+ - lib/generators/solid_cache/install/templates/config/solid_cache.yml.tt
107
108
  - lib/solid_cache.rb
108
109
  - lib/solid_cache/cluster.rb
109
110
  - lib/solid_cache/cluster/connections.rb