1
0
mirror of https://github.com/S2-/gitlit synced 2025-08-04 05:10:05 +02:00

add node modules to repo

This commit is contained in:
s2
2018-06-03 13:47:11 +02:00
parent e8c95255e8
commit d002126b72
4115 changed files with 440218 additions and 7519 deletions

37
node_modules/mksnapshot/lib/mksnapshot-call.js generated vendored Normal file
View File

@@ -0,0 +1,37 @@
(function() {
var callMksnapshot, fs, path, spawn;
fs = require('fs-extra');
path = require('path');
spawn = require('child_process').spawn;
callMksnapshot = function(mksnapshot, content, target, builddir, callback) {
return fs.writeFile(path.join(builddir, 'out.js'), content, function(error) {
var child;
if (error) {
return callback(error);
}
child = spawn(mksnapshot, ['out.cc', '--startup_blob', 'out.bin', 'out.js'], {
cwd: builddir
});
child.on('error', callback);
return child.on('close', function(code) {
if (code !== 0) {
return callback(new Error("mksnapshot returned " + code));
}
try {
fs.copySync(path.join(builddir, 'out.bin'), target);
} catch (_error) {
error = _error;
return callback(error);
}
return callback(null);
});
});
};
module.exports = callMksnapshot;
}).call(this);