torque/lib/header.js

22 lines
697 B
JavaScript
Raw Normal View History

2015-07-30 22:38:23 +08:00
var packageJSON = require("../package.json");
var fs = require("fs");
var headerString = "/**\n"
headerString += "Torque " + packageJSON.version + "\n";
headerString += packageJSON.description + "\n";
headerString += "https://github.com/cartodb/torque";
2015-07-30 22:58:17 +08:00
headerString += "\n**/\n\n\n";
fs.readFile("dist/torque.uncompressed.js", 'utf8', function(err, torque) {
if(!err){
var torqueString = headerString + torque;
2015-07-30 23:07:24 +08:00
fs.writeFile("dist/torque.uncompressed.js", torqueString);
2015-07-30 22:58:17 +08:00
}
});
fs.readFile("dist/torque.full.uncompressed.js", 'utf8', function(err, torque) {
if(!err){
var torqueString = headerString + torque;
2015-07-30 23:07:24 +08:00
fs.writeFile("dist/torque.full.uncompressed.js", torqueString);
2015-07-30 22:58:17 +08:00
}
2015-07-30 22:38:23 +08:00
});