<commit_before>/**
 * Ignition Client.
 * License: Q Public License 1.0 (QPL-1.0)
 * Copyright (c) <NAME>. All Rights Reserved.
 * BETA v0.91
 */



/* Initial Setup
-------------------------------------------------- */
var firstrun = true;

if (firstrun) {
    // Launch Renderer to Welcome / iNet check
}

/* Dev. run enviorment
-------------------------------------------------- */

if (process.platform == 'darwin') {
    process.env.NODE_ENV = 'osx';
}

else {
    process.env.NODE_ENV = 'pi';
}

global.config = require('konfig')();

var path = require('path');
global.appDir = path.dirname(require.main.filename);

/* Module dependencies
-------------------------------------------------- */
var common              = require('./local/common')
,   express             = require('express')
,   busboy              = require('busboy')
,   methodOverride      = require('method-override')
,   app                 = express()
,   http                = require('http').createServer(app)
,   fs                  = require('fs')
,   api                 = require('./local/api/api')
,   Insight             = require('insight')
,   pkg                 = require('./package.json');

global.__io             = require('socket.io').listen(http);
global.__api            = __io.of('/api');
global.__sessionFile    = appDir+"/config/profiles/Session.json";

api(__api);

//  Server Configuration

app.set('views', './local/render/');

app.engine('mustache', common.mu2express.engine);
app.set('view engine', 'mustache');

// app.use(common.express.logger('dev'));
// app.use(busboy());
app.use(methodOverride());

app.use(app.router);
app.use(common.express.compress());
app.use(common.express.static(__dirname + '/client'));


app.use(common.express.errorHandler());

/* Anonymous Analytics OPT-IN
-------------------------------------------------- */

var insight = new Insight({
    // Google Analytics tracking code
    trackingCode: 'UA-54752042-1',
    packageName: pkg.name,
    packageVersion: pkg.version
});

// // ask for permission the first time
// if (insight.optOut === undefined) {
//     return insight.askPermission();
// }
<commit_msg>Removal of misc. un-used code<commit_after>/**
 * Ignition Client.
 * License: Q Public License 1.0 (QPL-1.0)
 * Copyright (c) <NAME>. All Rights Reserved.
 * BETA v0.91
 */



/* Initial Setup
-------------------------------------------------- */
var firstrun = true;

if (firstrun) {
    // Launch Renderer to Welcome / iNet check
}

/* Dev. run enviorment
-------------------------------------------------- */

if (process.platform == 'darwin') {
    process.env.NODE_ENV    = 'osx';
}

else {
    process.env.NODE_ENV    = 'pi';
}

global.config               = require('konfig')();

var path                    = require('path');
global.appDir               = path.dirname(require.main.filename);

/* Module dependencies
-------------------------------------------------- */
var common              = require('./local/common')
,   express             = require('express')
,   busboy              = require('busboy')
,   methodOverride      = require('method-override')
,   app                 = express()
,   http                = require('http').createServer(app)
,   fs                  = require('fs')
,   api                 = require('./local/api/api')
,   Insight             = require('insight')
,   pkg                 = require('./package.json');

global.__io             = require('socket.io').listen(http);
global.__api            = __io.of('/api');
global.__sessionFile    = appDir+"/config/profiles/Session.json";

api(__api);

//  Server Configuration

app.set('views', './local/render/');

app.engine('mustache', common.mu2express.engine);
app.set('view engine', 'mustache');

// app.use(common.express.logger('dev'));
// app.use(busboy());
app.use(methodOverride());

app.use(app.router);
app.use(common.express.compress());
app.use(common.express.static(__dirname + '/client'));

app.use(common.express.errorHandler());

/* Anonymous Analytics OPT-IN
-------------------------------------------------- */

var insight = new Insight({
    // Google Analytics tracking code
    trackingCode: 'UA-54752042-1',
    packageName: pkg.name,
    packageVersion: pkg.version
});

// // ask for permission the first time
// if (insight.optOut === undefined) {
//     return insight.askPermission();
// }

{'fraction_non_alphanumeric': 0.2465627864344638, 'fraction_numerical': 0.007791017415215398, 'mean_word_length': 1.8510777269758327, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, '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': '1809423', 'n_tokens_mistral': 1251, 'n_tokens_neox': 1211, 'n_words': 250}