We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a8ac8bf commit 810b358Copy full SHA for 810b358
.gitignore
@@ -1,3 +1,4 @@
1
+_import/
2
_site/
3
.DS_Store
4
*.swp
_tasks/import.rb
@@ -2,6 +2,8 @@
require 'spidr'
require 'fileutils'
5
+IMPORT_DIR = '_import'
6
+
7
desc 'Spiders ruby-lang.org and imports HTML content'
8
task :import do
9
Spidr.site('http://www.ruby-lang.org/index.html') do |agent|
@@ -14,7 +16,7 @@
14
16
end
15
17
18
agent.every_ok_page do |page|
- local_path = page.url.path[1..-1]
19
+ local_path = File.join(IMPORT_DIR,page.url.path[1..-1])
20
21
if local_path[-1..-1] == '/'
22
local_path += 'index.html'
0 commit comments