<commit_before>// var express = require('express');
// var router = express.Router();
// var env = require('node-env-file');
// env('./.env')
// var fs = require('fs');
// var azure = require('azure-storage');
// var bigInt = require('big-integer');
// var blobService = azure.createBlobService();


// router.get('/', function(req, res, next) {
//   res.render('index')
// });

// router.get('/images', function(req,res){
//     var images = [];
//         blobService.listBlobsSegmented('imagecontainer', null, function(error, result, response){
//           if(!error){
//             images = result;
//             console.log(images.entries)
//              for(var i = 0; i < images.entries.length; i++){
//                 // using npm module bigInt, because the number of .NET ticks
//                 // is a number with too many digits for vanilla JavaScript
//                 // to perform accurate math on.
//                 var ticks = images.entries[i].name.slice(0,18);
//                 var ticksAtUnixEpoch = bigInt("621355968000000000")
//                 var ticksInt = bigInt(ticks);
//                 var ticksSinceUnixEpoch = ticksInt.minus(ticksAtUnixEpoch);
//                 var milliseconds = ticksSinceUnixEpoch.divide(10000)
//                 //Converting millisecond to dateTime client side so it will
//                 //display in the user's local timezone.
//                 images.entries[i].milliseconds = milliseconds.value
//               }
//             res.send(images);
//           } else {
//             res.send(error);
//           }
//         })
// })


// module.exports = router;<commit_msg>switching branches<commit_after>var express = require('express');
var router = express.Router();
var env = require('node-env-file');
env('./.env')
var fs = require('fs');
var azure = require('azure-storage');
var bigInt = require('big-integer');
var blobService = azure.createBlobService();


router.get('/', function(req, res, next) {
  res.render('index')
});

router.get('/images', function(req,res){
    var images = [];
        blobService.listBlobsSegmented('imagecontainer', null, function(error, result, response){
          if(!error){
            images = result;
            console.log(images.entries)
             for(var i = 0; i < images.entries.length; i++){
                // using npm module bigInt, because the number of .NET ticks
                // is a number with too many digits for vanilla JavaScript
                // to perform accurate math on.
                var ticks = images.entries[i].name.slice(0,18);
                var ticksAtUnixEpoch = bigInt("621355968000000000")
                var ticksInt = bigInt(ticks);
                var ticksSinceUnixEpoch = ticksInt.minus(ticksAtUnixEpoch);
                var milliseconds = ticksSinceUnixEpoch.divide(10000)
                //Converting millisecond to dateTime client side so it will
                //display in the user's local timezone.
                images.entries[i].milliseconds = milliseconds.value
              }
            res.send(images);
          } else {
            res.send(error);
          }
        })
})


module.exports = router;
{'fraction_non_alphanumeric': 0.14026299311208515, 'fraction_numerical': 0.016906700062617408, 'mean_word_length': 1.9338842975206612, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 2, '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': '1773891', 'n_tokens_mistral': 927, 'n_tokens_neox': 846, 'n_words': 217}