           page.story or []
 
         else
-          console.log "Unfamiliar action: #{action}"
+          log "Unfamiliar action:", action
           page.story
 
       # Add a blank journal if it does not exist.

#     npm install

# Standard lib
fs = require('fs')
path = require('path')
http = require('http')
child_process = require('child_process')

# From npm
mkdirp = require('mkdirp')
express = require('express')
hbs = require('hbs')
passportImport = require('passport')
OpenIDstrat = require('passport-openid').Strategy
WebSocketServer = require('ws').Server
spawn = require('child_process').spawn
path = require 'path'
glob = require 'glob'
es = require 'event-stream'
JSONStream = require 'JSONStream'

# Local files
random = require('./random_id')
defargs = require('./defaultargs')
util = require('../../../client/lib/util')

# pageFactory can be easily replaced here by requiring your own page handler
# factory, which gets called with the argv object, and then has get and put
# methods that accept the same arguments and callbacks. That would be the
# easiest way to use the Smallest Federated Wiki with a database backend.
pageFactory = require('./page')

# When the server factory is first started attempt to retrieve the gitlog.
gitlog = ''

  ###### Meta Routes ######
  # Send an array of pages in the database via json
  app.get('/system/slugs.json', cors, (req, res) ->
    fs.readdir(argv.db, (e, files) ->
      if e then return res.e e
      res.send(files)
    )
  )

  app.get('/system/plugins.json', cors, (req, res) ->
    fs.readdir(path.join(argv.c, 'plugins'), (e, files) ->
      if e then return res.e e
      res.send(files)
    )
  )

  app.get('/system/sitemap.json', cors, (req, res) ->
    fs.readdir(argv.db, (e, files) ->
      if e then return res.e e
      sitemap = []
      # used to make sure all of the files are read 
      # and processesed in the site map before responding
