Created
June 14, 2011 14:07
-
-
Save hryk/1024960 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/lib/page.rb b/lib/page.rb | |
| index 5c7071f..82e855e 100644 | |
| --- a/lib/page.rb | |
| +++ b/lib/page.rb | |
| @@ -4,8 +4,12 @@ require 'config' | |
| require 'lib' | |
| require 'related' | |
| require 'uploaded' | |
| +require 'fileutils' | |
| def page(name,title) | |
| + unless Dir.exist? topdir(name) | |
| + FileUtils.mkpath topdir(name) | |
| + end | |
| attr = SDBM.open("#{topdir(name)}/attr",0644); | |
| searchable = (attr['searchable'] == 'true' ? true : false) | |
| @robotspec = (searchable ? "index,follow" : "noindex,nofollow") | |
| @@ -19,6 +23,7 @@ def page(name,title) | |
| @title = title | |
| @urlroot = URLROOT | |
| @srcroot = SRCROOT | |
| + @gyazo_root = GYAZOROOT | |
| @related = related_html(@name,@title) | |
| @uploaded = uploaded_html | |
| erb :page |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment