redvex-ar_cache 0.1.4 → 0.1.5
Sign up to get free protection for your applications and to get access to all the features.
- data/Manifest +1 -0
- data/Rakefile +1 -1
- data/ar_cache.gemspec +2 -2
- data/lib/ar_cache.rb +1 -1
- metadata +2 -2
data/Manifest
CHANGED
data/Rakefile
CHANGED
@@ -2,7 +2,7 @@ require 'rubygems'
|
|
2
2
|
require 'rake'
|
3
3
|
require 'echoe'
|
4
4
|
|
5
|
-
Echoe.new('ar_cache', '0.1.
|
5
|
+
Echoe.new('ar_cache', '0.1.5') do |p|
|
6
6
|
p.description = "Performe ActiveRecord cache in File System for heavy and repetitive query."
|
7
7
|
p.url = "http://github.com/redvex/ar_cache"
|
8
8
|
p.author = "Gianni Mazza"
|
data/ar_cache.gemspec
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = %q{ar_cache}
|
5
|
-
s.version = "0.1.
|
5
|
+
s.version = "0.1.5"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["Gianni Mazza"]
|
@@ -10,7 +10,7 @@ Gem::Specification.new do |s|
|
|
10
10
|
s.description = %q{Performe ActiveRecord cache in File System for heavy and repetitive query.}
|
11
11
|
s.email = %q{redvex@me.com}
|
12
12
|
s.extra_rdoc_files = ["CHANGELOG", "lib/ar_cache.rb", "README.rdoc"]
|
13
|
-
s.files = ["CHANGELOG", "init.rb", "lib/ar_cache.rb", "Manifest", "Rakefile", "README.rdoc"
|
13
|
+
s.files = ["ar_cache.gemspec", "CHANGELOG", "init.rb", "lib/ar_cache.rb", "Manifest", "Rakefile", "README.rdoc"]
|
14
14
|
s.homepage = %q{http://github.com/redvex/ar_cache}
|
15
15
|
s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Ar_cache", "--main", "README.rdoc"]
|
16
16
|
s.require_paths = ["lib"]
|
data/lib/ar_cache.rb
CHANGED
@@ -126,7 +126,7 @@ module ArCache
|
|
126
126
|
def cache_reset?(file)
|
127
127
|
filename = File.join(RAILS_ROOT, "config", "database.yml")
|
128
128
|
dbconf = YAML.load_file(filename)[RAILS_ENV]
|
129
|
-
if dbconf["cache_expire"].nil?
|
129
|
+
if dbconf["cache_expire"].nil? or !File.exists?(file)
|
130
130
|
return false
|
131
131
|
else
|
132
132
|
return File.open(file).ctime + dbconf["cache_expire"] > Time.now
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: redvex-ar_cache
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gianni Mazza
|
@@ -33,13 +33,13 @@ extra_rdoc_files:
|
|
33
33
|
- lib/ar_cache.rb
|
34
34
|
- README.rdoc
|
35
35
|
files:
|
36
|
+
- ar_cache.gemspec
|
36
37
|
- CHANGELOG
|
37
38
|
- init.rb
|
38
39
|
- lib/ar_cache.rb
|
39
40
|
- Manifest
|
40
41
|
- Rakefile
|
41
42
|
- README.rdoc
|
42
|
-
- ar_cache.gemspec
|
43
43
|
has_rdoc: false
|
44
44
|
homepage: http://github.com/redvex/ar_cache
|
45
45
|
licenses:
|