 
     # Recent entries
     @app.get '/recents', (req, res) =>
+      numRecents = @config.numRecents ? @recentInfo.recentFiles.length
       markdown = """
       ## Recent Entries
 
       """
-      for file in @recentInfo.recentFiles
+      for file in @recentInfo.recentFiles[...numRecents]
         entryUrl = "/#{file.year}/#{file.month}/#{file.datepart}/#{file.slug}"
         ymd = @formatDate file.year, file.month, file.date
         markdown += "#{ymd} [#{file.title or '(untitled)'}](#{entryUrl})\n"

      err = @loadConfig()
      if not err?
        @logMessage "loaded #{path.basename @configFilename}"

    # Load page template and watch it for change
    @pageTemplate = fs.readFileSync @pageTemplateFilename, {encoding:'utf8'}

    files

  # Scan entries and update index
  createIndex: (numRecents) ->
    if not numRecents?
      numRecents = @config.numRecents ? 15
      if @config.numHomepageRecents?
        numRecents = Math.max @config.numHomepageRecents, numRecents
    @logMessage "indexing...", noNewline:true
    startTime = new Date().getTime()
    count = 0
