new implementation

This commit is contained in:
2016-07-03 04:37:03 +02:00
parent 011ac2d7b4
commit 5d00afcdf0
16 changed files with 76 additions and 16 deletions

View File

@@ -1,5 +1,15 @@
import * as plugins from "./smartgit.plugins";
import * as helpers from "./smartgit.helpers";
export let pull = (optionsArg:{path:string,ref?:string}) => {
}
export let add = (dirPathArg:string) => {
let done = plugins.Q.defer();
if(!helpers.isGitDirectory(dirPathArg)){
plugins.beautylog.error("smartgit.add expects a valif git directory!");
done.reject();
return done.promise;
};
// if everything is ok proceed
plugins.shelljs.exec("");
done.resolve(dirPathArg);
return done.promise;
};