Sha256: 94b6960c4ac26ff78b6d9cc264713d4871ff76a59ba5f085294bd46dbb9e1221

Contents?: true

Size: 912 Bytes

Versions: 25

Compression:

Stored size: 912 Bytes

Contents

var PATH = require("path");
var FS = require("fs");

function readFile(path) {
	var abs_path = PATH.join(__dirname, "lib", path);
	return FS.readFileSync(abs_path, "utf8");
}

function stripCommonJS(text) {
	return text.replace(/\/\/\.CommonJS(?:.|\n)*?\/\/\/CommonJS/g, "");
}

desc("Packages lib files into the one huge");
task("default", [], function(){
	var files = [readFile("CSSOM.js")];
	var index_file = readFile("index.js");

	(function(){
		var exports = {};
		function require(path) {
			var text = readFile(path + ".js");
			files.push(stripCommonJS(text).trimLeft());
			return {};
		}
		eval(index_file);
	})();

	var build_dir = PATH.join(__dirname, "build");
	try {
		FS.statSync(build_dir);
	} catch(e) {
		FS.mkdirSync(build_dir, 0755);
	}
	var build_path = PATH.join(build_dir, "CSSOM.js");
	FS.writeFileSync(build_path, files.join(""));
	process.stdout.write("build/CSSOM.js is done\n");
});

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
stylus-source-0.23.0 vendor/node_modules/cssom/Jakefile
stylus-source-0.22.6 vendor/node_modules/cssom/Jakefile
stylus-source-0.22.5 vendor/node_modules/cssom/Jakefile
stylus-source-0.22.4 vendor/node_modules/cssom/Jakefile
stylus-source-0.22.3 vendor/node_modules/cssom/Jakefile
stylus-source-0.22.2 vendor/node_modules/cssom/Jakefile
stylus-source-0.22.1 vendor/node_modules/cssom/Jakefile
stylus-source-0.22.0 vendor/node_modules/cssom/Jakefile
stylus-source-0.21.2 vendor/node_modules/cssom/Jakefile
stylus-source-0.21.1 vendor/node_modules/cssom/Jakefile
stylus-source-0.21.0 vendor/node_modules/cssom/Jakefile
stylus-source-0.20.1 vendor/node_modules/cssom/Jakefile
stylus-source-0.20.0 vendor/node_modules/cssom/Jakefile
stylus-source-0.19.8 vendor/node_modules/cssom/Jakefile
stylus-source-0.19.7 vendor/node_modules/cssom/Jakefile
stylus-source-0.19.6 vendor/node_modules/cssom/Jakefile
stylus-source-0.19.5 vendor/node_modules/cssom/Jakefile
stylus-source-0.19.4 vendor/node_modules/cssom/Jakefile
stylus-source-0.19.3 vendor/node_modules/cssom/Jakefile
stylus-source-0.19.2 vendor/node_modules/cssom/Jakefile