sitemap 0.2b → 0.2b2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/sitemap/generator.rb +2 -2
- data/sitemap.gemspec +1 -1
- data/test/sitemap_test.rb +1 -1
- metadata +5 -5
data/lib/sitemap/generator.rb
CHANGED
@@ -146,7 +146,7 @@ module Sitemap
|
|
146
146
|
FileUtils.mv(fragments.first.path, location)
|
147
147
|
else
|
148
148
|
remove_saved_files(location)
|
149
|
-
root = File.join(Pathname.new(location).dirname, "
|
149
|
+
root = File.join(Pathname.new(location).dirname, "sitemaps")
|
150
150
|
Dir.mkdir(root) unless File.directory?(root)
|
151
151
|
fragments.each_with_index do |fragment, i|
|
152
152
|
file_pattern = File.join(root, "sitemap-fragment-#{i + 1}.xml")
|
@@ -166,7 +166,7 @@ module Sitemap
|
|
166
166
|
end
|
167
167
|
|
168
168
|
def remove_saved_files(location)
|
169
|
-
root = File.join(Pathname.new(location).dirname, "
|
169
|
+
root = File.join(Pathname.new(location).dirname, "sitemaps")
|
170
170
|
Dir[File.join(root, "sitemap-fragment-*.xml")].each { |file| File.unlink(file) }
|
171
171
|
File.unlink(location) if File.exist?(location)
|
172
172
|
end
|
data/sitemap.gemspec
CHANGED
data/test/sitemap_test.rb
CHANGED
@@ -165,7 +165,7 @@ class SitemapTest < Test::Unit::TestCase
|
|
165
165
|
path :root
|
166
166
|
end
|
167
167
|
path = File.join(Dir.tmpdir, "sitemap.xml")
|
168
|
-
root = File.join(Dir.tmpdir, "
|
168
|
+
root = File.join(Dir.tmpdir, "sitemaps") # Directory is being removed at the end of the test.
|
169
169
|
assert !File.directory?(root)
|
170
170
|
Sitemap::Generator.instance.build!
|
171
171
|
Sitemap::Generator.instance.save(path)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sitemap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2b2
|
5
5
|
prerelease: 3
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -13,7 +13,7 @@ date: 2012-03-02 00:00:00.000000000Z
|
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: sqlite3
|
16
|
-
requirement: &
|
16
|
+
requirement: &12238460 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: '0'
|
22
22
|
type: :development
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *12238460
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: nokogiri
|
27
|
-
requirement: &
|
27
|
+
requirement: &12233580 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,7 +32,7 @@ dependencies:
|
|
32
32
|
version: '0'
|
33
33
|
type: :development
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *12233580
|
36
36
|
description: A simple ruby on rails sitemap generator
|
37
37
|
email: daniel@viseztrance.com
|
38
38
|
executables: []
|