3
0
mirror of https://github.com/reality/dbot.git synced 2024-11-27 14:29:29 +01:00

web interface test

This commit is contained in:
Luke Slater 2011-09-13 21:23:46 +01:00
parent 3408be26ac
commit 43ed7fb570
3 changed files with 33 additions and 0 deletions

4
modules/views/index.jade Normal file
View File

@ -0,0 +1,4 @@
div#main
div#title depressionbot web interface
p
| Bitch please

View File

@ -0,0 +1,6 @@
!!! 5
html(lang: 'en')
head
meta(charset: 'utf-8')
title depressionbot web interface
body!= body

23
modules/web.js Normal file
View File

@ -0,0 +1,23 @@
var express = require('express');
var app = express.createServer();
var pub = '../public';
app.use(express.compiler({ src: pub, enable: ['sass'] }));
app.use(express.static(pub));
app.set('view engine', 'jade');
var webInterface = function(dbot) {
var dbot = dbot;
app.get('/', function(req, res) {
res.render('index', { });
});
app.listen(1337);
return { };
};
exports.fetch = function(dbot) {
return webInterface(dbot);
};