<commit_before>(function(exports) {
  var fs = require("fs");
  var os = require("os");
  var path = require("path");
  var child_process = require("child_process");
  var njds = require("nodejs-disks");

  var selectedItems = [];
  var activeItem = null;
  var activeItemIndex = 0;
  var activeListEl = null;

  var pathHistory = [];

  var openItem = function(item) {
    if(!item) return;
    if(item.type == "directory") {
        if(item.name == "..") {

          if(item.root == item.directory) {
            loadDrives();
            return;
          }
        }
        process.chdir(process.cwd() + "/" + item.textContent);
        loadDirectory();
    } else
    if(item.type == "file") {
      var child = child_process.spawn("start \"" + process.cwd() + "/" + item.textContent + "\"", [], {
        detached: true,
        stdio: [ 'ignore' ]
      });

      child.unref();
    } else
    if(item.type == "drive") {
      switch(os.platform().toLowerCase()) {
        case 'win32':
          process.chdir(item.textContent + "\\");
          loadDirectory();
          break;
        default:
          process.chdir(item.getAttribute("mountpoint"));
          loadDirectory();
          break;
      }
    }
  };

  var deselectAll = function() {
    for(var i=0; selectedItems.length > i; i++) {<commit_msg>Added proper opening of files in windows<commit_after>(function(exports) {
  var fs = require("fs");
  var os = require("os");
  var path = require("path");
  var child_process = require("child_process");
  var njds = require("nodejs-disks");

  var selectedItems = [];
  var activeItem = null;
  var activeItemIndex = 0;
  var activeListEl = null;

  var pathHistory = [];

  var openItem = function(item) {
    if(!item) return;
    if(item.type == "directory") {
        if(item.name == "..") {

          if(item.root == item.directory) {
            loadDrives();
            return;
          }
        }
        process.chdir(process.cwd() + "/" + item.textContent);
        loadDirectory();
    } else
    if(item.type == "file") {
      switch(os.platform().toLowerCase()) {

        case "linux":
          // Linux handles opening files differently. It's defined by
          // the window managers / desktop environments / whatever they
          // choose to run their software from... 
          //break;
        case "win32":
        default:
          var child = child_process.exec(item.textContent);
          child.unref();
          break;
      }
    } else
    if(item.type == "drive") {
      switch(os.platform().toLowerCase()) {
        case 'win32':
          process.chdir(item.textContent + "\\");
          loadDirectory();
          break;
        default:
          process.chdir(item.getAttribute("mountpoint"));
          loadDirectory();
          break;
      }
    }
  };

  var deselectAll = function() {
    for(var i=0; selectedItems.length > i; i++) {
{'fraction_non_alphanumeric': 0.15471698113207547, 'fraction_numerical': 0.003430531732418525, 'mean_word_length': 2.0438413361169103, 'pattern_counts': {'":': 2, '<': 3, '<?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': '294547', 'n_tokens_mistral': 876, 'n_tokens_neox': 859, 'n_words': 185}