Skip to content

Instantly share code, notes, and snippets.

@rue
Created December 11, 2008 17:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rue/34798 to your computer and use it in GitHub Desktop.
Save rue/34798 to your computer and use it in GitHub Desktop.
# Directory in which the wiki pages live
Giraffe.wikiroot = "/Users/ruerue/code/rubinius/master/doc"
# Directory in which .git lives
Giraffe.reporoot = "#{Giraffe.wikiroot}/.."
# Append extension to *all* page name candidates
Giraffe.to_filename = lambda {|uri| uri + ".txt" }
Giraffe.to_uri = lambda {|file| file.chomp ".txt" }
# No showing stuff other than .txt for now
Giraffe.list_filter = lambda {|file| file =~ /\.txt$/ }
# Resource files allowed
RESOURCES = { "png" => {:mime => "image/png"}
}
Giraffe.resource_filter = lambda {|uri|
uri.match /.+\.(.+)$/
RESOURCES[$1]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment