Aufenthaltsraum Server Maintenance Feed

The wiki is online again.

The self-hosted wiki mirror is online again. It is, however, not a full-blown Gollum instance anymore, but just a bunch of poorly styled HTML pages. It does what it should be doing, though.

Bonus: Here is the crappy Ruby script which generates the pages:

require 'rubygems'
require 'gollum-lib'
require 'fileutils'

wiki = Gollum::Wiki.new("../stuff.wiki.git")

preprefix = "<html><head><meta http-equiv=\"Content-Type\"" +
  " content=\"text/html; charset=utf-8\"><title>Aufenthaltsraum Wiki: "
prefix = "</title></head><body>"
suffix = "<hr><a href=\"/Home\">Home</a> | " +
  "<a href=\"/pages.html\">List of Pages</a></body></html>"

page_list = preprefix + "List of Pages" + prefix + "<ul>"

wiki.pages.each do |p|
  path = p.escaped_url_path
  title = p.title
  page_list += "<li><a href=\"" + path + "\">" + title + "</a></li>"
  FileUtils::mkdir_p path
  File.write(path + '/index.html',
             preprefix + title + prefix + p.formatted_data + suffix)
end

page_list += "</ul>" + prefix
File.write("pages.html", page_list)