<commit_before>#!/usr/bin/env node
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

const path = require('path'),
      spawn = require('child_process').spawn;


const BIN_ROOT = path.join(__dirname, '..', 'server', 'bin');

startServer();

function startServer() {
  var fabPath = path.join(BIN_ROOT, 'fxa-content-server.js');
  var fxaccntbridge = spawn('node', [fabPath]);
  fxaccntbridge.stdout.on('data', function(data) {
    console.log('fxa-content-server:', data.toString('utf8').trim());
  });
  fxaccntbridge.stderr.on('data', function(data) {
    console.log('fxa-content-server err:', data.toString('utf8').trim());
  });
  fxaccntbridge.on('exit', function(code, signal) {
    console.log('fxa-content-server killed, existing');
    process.exit(1);
  });<commit_msg>In the startup script, delete the port so that travis is happy<commit_after>#!/usr/bin/env node
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

const path = require('path'),
      spawn = require('child_process').spawn;


const BIN_ROOT = path.join(__dirname, '..', 'server', 'bin');

startServer();

function startServer() {
  process.chdir(path.dirname(__dirname));
  // We'll get PORT via config/local.json
  // This is required for Travis-CI to work correctly.
  delete process.env['PORT'];

  var fabPath = path.join(BIN_ROOT, 'fxa-content-server.js');
  var fxaccntbridge = spawn('node', [fabPath]);
  fxaccntbridge.stdout.on('data', function(data) {
    console.log('fxa-content-server:', data.toString('utf8').trim());
  });
  fxaccntbridge.stderr.on('data', function(data) {
    console.log('fxa-content-server err:', data.toString('utf8').trim());
  });
  fxaccntbridge.on('exit', function(code, signal) {
    console.log('fxa-content-server killed, existing');
    process.exit(1);
  });
{'fraction_non_alphanumeric': 0.17152412804586717, 'fraction_numerical': 0.006688963210702341, 'mean_word_length': 4.183168316831683, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '733761', 'n_tokens_mistral': 698, 'n_tokens_neox': 678, 'n_words': 173}