<commit_before>var express = require('express');
var router = express.Router();

var crypto = require('crypto');
var secrets = require('../secrets');

router.post('/push', function(req, res, next) {
  var payload = JSON.stringify(req.body);

  var hash = crypto.createHmac("sha1", secrets.github_token).update(payload).digest("hex");

  if (req.headers["x-hub-signature"] === "sha1=" + hash){

    var spawn = require('child_process').spawn;
    var child = spawn('./pull.sh');

    child.stdout.on('data', (data) => {
<<<<<<< HEAD
      res.status(201).json({
        "hub-delivery": req.headers["x-github-delivery"],
        "hub-event": req.headers["x-github-event"],
        "response": data.toString(),
=======
      res.json({
        "hub-delivery": req.headers["x-github-delivery"],
        "hub-event": req.headers["x-github-event"],
        "response": 'data.toString()',
>>>>>>> 7c55b9f891251be5717c7171145fbaa8573f58e2

        "commit": req.body.after,
        "messages": req.body.commits
      })
    });

    return
  }

 res.status(403).json({"reponse": "forbidden"});
});

module.exports = router;<commit_msg>Fixed merge<commit_after>var express = require('express');
var router = express.Router();

var crypto = require('crypto');
var secrets = require('../secrets');

router.post('/push', function(req, res, next) {
  var payload = JSON.stringify(req.body);

  var hash = crypto.createHmac("sha1", secrets.github_token).update(payload).digest("hex");

  if (req.headers["x-hub-signature"] === "sha1=" + hash){

    var spawn = require('child_process').spawn;
    var child = spawn('./pull.sh');

    child.stdout.on('data', (data) => {
      res.status(201).json({
        "hub-delivery": req.headers["x-github-delivery"],
        "hub-event": req.headers["x-github-event"],
        "response": data.toString(),

        "commit": req.body.after,
        "messages": req.body.commits
      })
    });

    return
  }

 res.status(403).json({"reponse": "forbidden"});
});

module.exports = router;
{'fraction_non_alphanumeric': 0.2078373015873016, 'fraction_numerical': 0.021825396825396824, 'mean_word_length': 3.482222222222222, 'pattern_counts': {'":': 15, '<': 10, '<?xml version=': 0, '>': 12, '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': '4460280', 'n_tokens_mistral': 691, 'n_tokens_neox': 646, 'n_words': 111}