<commit_before>// Build OpenAF
//
plugin("ZIP");

var params = processExpr();

var OPENAF_BUILD_HOME = (isUndefined(params.withDir)) ? "." : params.withDir;
var OPENAF_JSON = (isDef(params.withJSON)) ? params.withJSON : undefined;
var OPENAF_DIST = (isDef(params.withDist)) ? params.withDist : undefined;
var OPENAF_LIB = OPENAF_BUILD_HOME + "/lib";
var OPENAF_SRC = OPENAF_BUILD_HOME + "/src";
var OPENAF_BIN = OPENAF_BUILD_HOME + "/bin";
var OPENAF_JS = OPENAF_BUILD_HOME + "/js";
var JAVAC = "javac";
var smallClassPath = "";

var EXTERNAL = false;
if (isDefined(params.external)) EXTERNAL = true;

log("Building params:");
log("   BUILD_HOME = " + OPENAF_BUILD_HOME);
log("   JSON       = " + OPENAF_JSON);
log("   DIST       = " + OPENAF_DIST);
log("   LIB        = " + OPENAF_LIB);
log("   SRC        = " + OPENAF_SRC);
log("   BIN        = " + OPENAF_BIN);
log("   JS         = " + OPENAF_JS);
log("   JAVAC      = " + JAVAC);
log("   EXTERNAL   = " + EXTERNAL);

var INTERNAL_LICENSE = "See license info in openaf.jar/LICENSE and openaf.jar/LICENSES.txt";
var EXTERNAL_LICENSE = "See license info in openaf.jar/LICENSE and openaf.jar/LICENSES.txt";

function buildDeps() {
	loadUnderscore();

	// Check javascript dependencies
	var l = io.listFilenames(OPENAF_BUILD_HOME + "/js");
	var ss = {};

	for (var i in l) {
		if (l[i].match(/\.js$/))
			ss[l[i]] = _.uniq(io.readFileString(l[i]).match(/plugin\([^\)]+\)/g))
	};
<commit_msg>buildos: remove underscore dep<commit_after>// Build OpenAF
//
plugin("ZIP");

var params = processExpr();

var OPENAF_BUILD_HOME = (isUndefined(params.withDir)) ? "." : params.withDir;
var OPENAF_JSON = (isDef(params.withJSON)) ? params.withJSON : undefined;
var OPENAF_DIST = (isDef(params.withDist)) ? params.withDist : undefined;
var OPENAF_LIB = OPENAF_BUILD_HOME + "/lib";
var OPENAF_SRC = OPENAF_BUILD_HOME + "/src";
var OPENAF_BIN = OPENAF_BUILD_HOME + "/bin";
var OPENAF_JS = OPENAF_BUILD_HOME + "/js";
var JAVAC = "javac";
var smallClassPath = "";

var EXTERNAL = false;
if (isDefined(params.external)) EXTERNAL = true;

log("Building params:");
log("   BUILD_HOME = " + OPENAF_BUILD_HOME);
log("   JSON       = " + OPENAF_JSON);
log("   DIST       = " + OPENAF_DIST);
log("   LIB        = " + OPENAF_LIB);
log("   SRC        = " + OPENAF_SRC);
log("   BIN        = " + OPENAF_BIN);
log("   JS         = " + OPENAF_JS);
log("   JAVAC      = " + JAVAC);
log("   EXTERNAL   = " + EXTERNAL);

var INTERNAL_LICENSE = "See license info in openaf.jar/LICENSE and openaf.jar/LICENSES.txt";
var EXTERNAL_LICENSE = "See license info in openaf.jar/LICENSE and openaf.jar/LICENSES.txt";

function buildDeps() {
	// Check javascript dependencies
	var l = io.listFilenames(OPENAF_BUILD_HOME + "/js");
	var ss = {};

	function u(anArr) {
		var ar = [];
		for(var ii in anArr) {
			if (ar.indexOf(anArr[ii]) < 0) ar.push(anArr[ii]);
		}

		return ar;
	}

	for (var i in l) {
		if (l[i].match(/\.js$/))
			ss[l[i]] = u(io.readFileString(l[i]).match(/plugin\([^\)]+\)/g));
	};

{'fraction_non_alphanumeric': 0.1697674418604651, 'fraction_numerical': 0.0003322259136212625, 'mean_word_length': 3.6039755351681957, 'pattern_counts': {'":': 0, '<': 4, '<?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': '3888065', 'n_tokens_mistral': 1192, 'n_tokens_neox': 1193, 'n_words': 250}