<commit_before>global.root = __dirname;

var express = require('express');
var bodyParser = require('body-parser');
var settings = require(global.root + '/server/config/ExternalSettings.js');

var app = express();
var PORT = 8080;

settings("favicon",app);
settings("paths");

// part of express
app.use(bodyParser.json());

// routing
require(global.controllers + '/RouteRegistration.js')(app, express);

var server = app.listen(PORT, '0.0.0.0', function() {
    console.log('Chat listening on port ' + PORT);
});
<commit_msg>socket.io<commit_after>global.root = __dirname;

// import express
var express = require('express');

// init app
var app = express();

// http server and sockets
var server = require('http').Server(app);
var io = require('socket.io')(http);

// chat functionality
require(global.controllers + '/chatController.js')(io);

// import config manager
var settings = require(global.root + '/server/config/ExternalSettings.js');

var PORT = 8080;

// config
settings("favicon",app);
settings("paths");

// routing and middleware
require(global.controllers + '/mainController.js')(app, express);

server.listen(PORT, function() {
    console.log('Chat listening on port ' + PORT);
});
{'fraction_non_alphanumeric': 0.1719269102990033, 'fraction_numerical': 0.009966777408637873, 'mean_word_length': 4.9950248756218905, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 1, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2420629', 'n_tokens_mistral': 373, 'n_tokens_neox': 361, 'n_words': 90}