Build server prototype (integration with GitHub / NuGet / etc)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
micro-build-server/BuildServer/lib/tasks/deletefromcode.js

22 lines
572 B

"use strict";
const path = require("path");
const fse = require("fs-extra");
module.exports = (params, processor) => ({
"process": () => {
const sourceFilePath = path.join(processor.context.exported, params.filename);
processor.onInfo(`Deleting ${sourceFilePath}`);
fse.remove(sourceFilePath, (err) => {
if (err) {
processor.onError(`Unable to delete file: ${err}`);
} else {
processor.onInfo("Deleted file");
}
return processor.done();
});
}
});