now can remove files

This commit is contained in:
Philipp Kunz 2016-03-21 00:28:29 +01:00
parent 580cb95aa7
commit 20a3fdba03
12 changed files with 79 additions and 12 deletions

4
dist/index.js vendored
View File

@ -1,5 +1,6 @@
/// <reference path="./typings/main.d.ts" /> /// <reference path="./typings/main.d.ts" />
"use strict"; "use strict";
var plugins = require("./smartfile.plugins");
var SmartfileChecks = require("./smartfile.checks"); var SmartfileChecks = require("./smartfile.checks");
var SmartfileFsaction = require("./smartfile.fsaction"); var SmartfileFsaction = require("./smartfile.fsaction");
var SmartfileGet = require("./smartfile.get"); var SmartfileGet = require("./smartfile.get");
@ -7,6 +8,7 @@ var SmartfileLocal = require("./smartfile.local");
var SmartfileRemote = require("./smartfile.remote"); var SmartfileRemote = require("./smartfile.remote");
var smartfile = { var smartfile = {
fsaction: SmartfileFsaction, fsaction: SmartfileFsaction,
fs: plugins.fs,
checks: SmartfileChecks, checks: SmartfileChecks,
get: SmartfileGet, get: SmartfileGet,
local: SmartfileLocal, local: SmartfileLocal,
@ -15,4 +17,4 @@ var smartfile = {
}; };
module.exports = smartfile; module.exports = smartfile;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImluZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLDRDQUE0Qzs7QUFHNUMsSUFBTyxlQUFlLFdBQVcsb0JBQW9CLENBQUMsQ0FBQztBQUN2RCxJQUFPLGlCQUFpQixXQUFXLHNCQUFzQixDQUFDLENBQUM7QUFDM0QsSUFBTyxZQUFZLFdBQVcsaUJBQWlCLENBQUMsQ0FBQztBQUNqRCxJQUFPLGNBQWMsV0FBVyxtQkFBbUIsQ0FBQyxDQUFDO0FBQ3JELElBQU8sZUFBZSxXQUFXLG9CQUFvQixDQUFDLENBQUM7QUFHdkQsSUFBSSxTQUFTLEdBQU87SUFDaEIsUUFBUSxFQUFFLGlCQUFpQjtJQUMzQixNQUFNLEVBQUUsZUFBZTtJQUN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BvcnQgU21hcnRmaWxlRnNhY3Rpb24gPSByZXF1aXJlKFwiLi9zbWFydGZpbGUuZnNhY3Rpb25cIik7XG5pbXBvcnQgU21hcnRmaWxlR2V0ID0gcmVxdWlyZShcIi4vc21hcnRmaWxlLmdldFwiKTtcbmltcG9ydCBTbWFydGZpbGVMb2NhbCA9IHJlcXVpcmUoXCIuL3NtYXJ0ZmlsZS5sb2NhbFwiKTtcbmltcG9ydCBTbWFydGZpbGVSZW1vdGUgPSByZXF1aXJlKFwiLi9zbWFydGZpbGUucmVtb3RlXCIpO1xuXG5cbnZhciBzbWFydGZpbGU6YW55ID0ge1xuICAgIGZzYWN0aW9uOiBTbWFydGZpbGVGc2FjdGlvbixcbiAgICBmczogcGx1Z2lucy5mcyxcbiAgICBjaGVja3M6IFNtYXJ0ZmlsZUNoZWNrcyxcbiAgICBnZXQ6IFNtYXJ0ZmlsZUdldCxcbiAgICBsb2NhbDogU21hcnRmaWxlTG9jYWwsXG4gICAgcmVtb3RlOiBTbWFydGZpbGVSZW1vdGUsXG4gICAgcmVxdWlyZVJlbG9hZDogU21hcnRmaWxlTG9jYWwucmVxdWlyZVJlbG9hZFxufTtcblxuZXhwb3J0ID0gc21hcnRmaWxlO1xuIl0sInNvdXJjZVJvb3QiOiIvc291cmNlLyJ9

View File

@ -29,5 +29,11 @@ exports.fileExists = function (filePath) {
}); });
return done.promise; return done.promise;
}; };
exports.isDirectory = function (pathArg) {
return plugins.fs.statSync(pathArg).isDirectory();
};
exports.isFile = function (pathArg) {
return plugins.fs.statSync(pathArg).isFile();
};
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNtYXJ0ZmlsZS5jaGVja3MudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLDRDQUE0QztBQUM1QyxJQUFPLE9BQU8sV0FBVyxxQkFBcUIsQ0FBQyxDQUFDO0FBRWhEOzs7O0dBSUc7QUFDUSxzQkFBYyxHQUF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Rpb24ocGF0aEFyZyk6Ym9vbGVhbntcbiAgICByZXR1cm4gcGx1Z2lucy5mcy5zdGF0U3luYyhwYXRoQXJnKS5pc0RpcmVjdG9yeSgpO1xufTtcblxuZXhwb3J0IGxldCBpc0ZpbGUgPSBmdW5jdGlvbihwYXRoQXJnKTpib29sZWFue1xuICAgIHJldHVybiBwbHVnaW5zLmZzLnN0YXRTeW5jKHBhdGhBcmcpLmlzRmlsZSgpO1xufTtcbiJdLCJzb3VyY2VSb290IjoiL3NvdXJjZS8ifQ==

View File

@ -2,7 +2,26 @@
"use strict"; "use strict";
var plugins = require("./smartfile.plugins"); var plugins = require("./smartfile.plugins");
exports.copy = function (fromArg, toArg) { exports.copy = function (fromArg, toArg) {
plugins.shelljs.cp("-r", fromArg, toArg); var done = plugins.q.defer();
plugins.fs.copy(fromArg, toArg, {}, function () {
done.resolve();
});
return done.promise;
};
exports.copySync = function (fromArg, toArg) {
plugins.fs.copySync(fromArg, toArg);
return true;
};
exports.remove = function (pathArg) {
var done = plugins.q.defer();
plugins.fs.remove(pathArg, function () {
done.resolve();
});
return done.promise;
};
exports.removeSync = function (pathArg) {
plugins.fs.removeSync(pathArg);
return true;
}; };
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNtYXJ0ZmlsZS5mc2FjdGlvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSw0Q0FBNEM7O0FBRTVDLElBQU8sT0FBTyxXQUFXLHFCQUFxQixDQUFDLENBQUM7QUFFckMsWUFBSSxHQUFHLFVBQVMsT0FBYyxFQUFDLEtBQVk7SUFDbEQsT0FBTyxDQUFDLE9BQU8sQ0FBQyxFQUFFLENBQUMsSUFBSSxFQUFDLE9BQU8sRUFBQyxLQUFLLENBQUMsQ0FBQztBQUMzQyxDQUFDLENBQUMiLCJmaWxlIjoic21hcnRmaWxlLmZzYWN0aW9uLmpzIiwic291cmNlc0NvbnRlbnQiOlsiLy8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c3RyaW5nLHRvQXJnOnN0cmluZyk6Ym9vbGVhbntcbiAgICBwbHVnaW5zLmZzLmNvcHlTeW5jKGZyb21BcmcsdG9BcmcpO1xuICAgIHJldHVybiB0cnVlO1xufTtcblxuZXhwb3J0IGxldCByZW1vdmUgPSBmdW5jdGlvbihwYXRoQXJnOnN0cmluZyl7XG4gICAgdmFyIGRvbmUgPSBwbHVnaW5zLnEuZGVmZXIoKTtcbiAgICBwbHVnaW5zLmZzLnJlbW92ZShwYXRoQXJnLGZ1bmN0aW9uKCl7XG4gICAgICAgIGRvbmUucmVzb2x2ZSgpO1xuICAgIH0pO1xuICAgIHJldHVybiBkb25lLnByb21pc2U7XG59O1xuXG5leHBvcnQgbGV0IHJlbW92ZVN5bmMgPSBmdW5jdGlvbihwYXRoQXJnOnN0cmluZyk6Ym9vbGVhbntcbiAgICBwbHVnaW5zLmZzLnJlbW92ZVN5bmMocGF0aEFyZyk7XG4gICAgcmV0dXJuIHRydWU7XG59OyJdLCJzb3VyY2VSb290IjoiL3NvdXJjZS8ifQ==

View File

@ -13,6 +13,5 @@ exports.vinylFile = require("vinyl-file");
exports.yaml = require("js-yaml"); exports.yaml = require("js-yaml");
exports.request = require("request"); exports.request = require("request");
exports.requireReload = require("require-reload"); exports.requireReload = require("require-reload");
exports.shelljs = require("shelljs");
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNtYXJ0ZmlsZS5wbHVnaW5zLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7QUFBQSw0Q0FBNEM7QUFDakMsaUJBQVMsR0FBRyxPQUFPLENBQUMsV0FBVyxDQUFDLENBQUM7QUFDakMsVUFBRSxHQUFHLE9BQU8sQ0FBQyxVQUFVLENBQUMsQ0FBQztBQUN6QixZQUFJLEdBQUcsT0FBTyxDQUFDLE1BQU0sQ0FBQyxDQUFDO0FBQ3ZCLFNBQUMsR0FBRztJQUNYLFNBQVMsRUFBRSxPQUFPL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yxnQkFBZ0IsQ0FBQyxDQUFDIiwiZmlsZSI6InNtYXJ0ZmlsZS5wbHVnaW5zLmpzIiwic291cmNlc0NvbnRlbnQiOlsiLy8vIDxyZWZlcmVuY2UgcGF0aD1cIi4vdHlwaW5ncy9tYWluLmQudHNcIiAvPlxuZXhwb3J0IGxldCBiZWF1dHlsb2cgPSByZXF1aXJlKFwiYmVhdXR5bG9nXCIpO1xuZXhwb3J0IGxldCBmcyA9IHJlcXVpcmUoXCJmcy1leHRyYVwiKTtcbmV4cG9ydCBsZXQgZ3VscCA9IHJlcXVpcmUoXCJndWxwXCIpO1xuZXhwb3J0IGxldCBnID0ge1xuICAgIHJlbW90ZVNyYzogcmVxdWlyZShcImd1bHAtcmVtb3RlLXNyY1wiKVxufTtcbmV4cG9ydCBsZXQgcGF0aCA9IHJlcXVpcmUoXCJwYXRoXCIpO1xuZXhwb3J0IGxldCBxID0gcmVxdWlyZShcInFcIik7XG5leHBvcnQgbGV0IHZpbnlsID0gcmVxdWlyZShcInZpbnlsXCIpO1xuZXhwb3J0IGxldCB2aW55bEZpbGUgPSByZXF1aXJlKFwidmlueWwtZmlsZVwiKTtcbmV4cG9ydCBsZXQgeWFtbCA9IHJlcXVpcmUoXCJqcy15YW1sXCIpO1xuZXhwb3J0IGxldCByZXF1ZXN0ID0gcmVxdWlyZShcInJlcXVlc3RcIik7XG5leHBvcnQgbGV0IHJlcXVpcmVSZWxvYWQgPSByZXF1aXJlKFwicmVxdWlyZS1yZWxvYWRcIik7XG4iXSwic291cmNlUm9vdCI6Ii9zb3VyY2UvIn0=

View File

@ -33,7 +33,6 @@
"q": "1.4.1", "q": "1.4.1",
"request": "^2.69.0", "request": "^2.69.0",
"require-reload": "0.2.2", "require-reload": "0.2.2",
"shelljs": "^0.6.0",
"vinyl": "1.1.1", "vinyl": "1.1.1",
"vinyl-file": "2.0.0" "vinyl-file": "2.0.0"
}, },

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
{"version":3,"file":"test.js","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artfile.fsaction.copy("./test/mytest.yaml","./test/temp/mytestRenamed.yaml")
}); });
}); });
describe(".remove()",function(){
it("should remove an entire directory",function(){
});
it("should remove single files")
});
}); });
describe(".local".yellow,function(){ describe(".local".yellow,function(){
describe("toGulpStreamSync() and toGulpDestSync",function(){ describe("toGulpStreamSync() and toGulpDestSync",function(){

View File

@ -10,6 +10,7 @@ import SmartfileRemote = require("./smartfile.remote");
var smartfile:any = { var smartfile:any = {
fsaction: SmartfileFsaction, fsaction: SmartfileFsaction,
fs: plugins.fs,
checks: SmartfileChecks, checks: SmartfileChecks,
get: SmartfileGet, get: SmartfileGet,
local: SmartfileLocal, local: SmartfileLocal,

View File

@ -30,3 +30,11 @@ export let fileExists = function(filePath){
}); });
return done.promise; return done.promise;
}; };
export let isDirectory = function(pathArg):boolean{
return plugins.fs.statSync(pathArg).isDirectory();
};
export let isFile = function(pathArg):boolean{
return plugins.fs.statSync(pathArg).isFile();
};

View File

@ -1,7 +1,30 @@
/// <reference path="./typings/main.d.ts" /> /// <reference path="./typings/main.d.ts" />
import plugins = require("./smartfile.plugins"); import plugins = require("./smartfile.plugins");
import SmartfileChecks = require("./smartfile.checks");
export let copy = function(fromArg:string,toArg:string){ export let copy = function(fromArg:string, toArg:string){
plugins.shelljs.cp("-r",fromArg,toArg); var done = plugins.q.defer();
plugins.fs.copy(fromArg,toArg,{},function(){
done.resolve();
});
return done.promise;
};
export let copySync = function(fromArg:string,toArg:string):boolean{
plugins.fs.copySync(fromArg,toArg);
return true;
};
export let remove = function(pathArg:string){
var done = plugins.q.defer();
plugins.fs.remove(pathArg,function(){
done.resolve();
});
return done.promise;
};
export let removeSync = function(pathArg:string):boolean{
plugins.fs.removeSync(pathArg);
return true;
}; };

View File

@ -12,4 +12,3 @@ export let vinylFile = require("vinyl-file");
export let yaml = require("js-yaml"); export let yaml = require("js-yaml");
export let request = require("request"); export let request = require("request");
export let requireReload = require("require-reload"); export let requireReload = require("require-reload");
export let shelljs = require("shelljs");