From bf27aaf1675f6301b5e63a95c21442516df92c25 Mon Sep 17 00:00:00 2001 From: Phil Kunz Date: Sat, 25 Jun 2016 13:07:24 +0200 Subject: [PATCH] update structure --- ts/smartssh.classes.sshconfig.ts | 3 ++- ts/smartssh.classes.sshkey.ts | 8 ++++---- ts/typings.json | 8 -------- 3 files changed, 6 insertions(+), 13 deletions(-) delete mode 100644 ts/typings.json diff --git a/ts/smartssh.classes.sshconfig.ts b/ts/smartssh.classes.sshconfig.ts index 6c290b4..48a5b9d 100644 --- a/ts/smartssh.classes.sshconfig.ts +++ b/ts/smartssh.classes.sshconfig.ts @@ -15,9 +15,10 @@ export class SshConfig { storeConfig(dirPathArg:string){ let done = plugins.q.defer(); let configArray:configObject[]; - + return done.promise; } + readConfig }; let createConfigPath = () => { diff --git a/ts/smartssh.classes.sshkey.ts b/ts/smartssh.classes.sshkey.ts index 91ba533..a93f5bc 100644 --- a/ts/smartssh.classes.sshkey.ts +++ b/ts/smartssh.classes.sshkey.ts @@ -72,12 +72,12 @@ export class SshKey { read(filePathArg){ } - store(filePathArg?:string){ - let filePathObj = plugins.path.parse(filePathArg); + store(dirPathArg?:string){ + let filePathObj = plugins.path.parse(dirPathArg); if(filePathObj.ext = ".priv"){ - plugins.smartfile.memory.toFsSync(this._privKey,filePathArg); + plugins.smartfile.memory.toFsSync(this._privKey,dirPathArg); } else if (filePathObj.ext = ".pub"){ - plugins.smartfile.memory.toFsSync(this._pubKey,filePathArg); + plugins.smartfile.memory.toFsSync(this._pubKey,dirPathArg); } else { //we assume we are given a directory as filePathArg, so we store the whole key plugins.fs.ensureDirSync(filePathObj.dir); this.store(plugins.path.join(filePathObj.dir,"key.priv")); // call this function recursivly diff --git a/ts/typings.json b/ts/typings.json deleted file mode 100644 index 16d0dcf..0000000 --- a/ts/typings.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "version": false, - "dependencies": {}, - "ambientDependencies": { - "colors": "registry:dt/colors#0.6.0-1+20160317120654", - "node": "registry:dt/node#4.0.0+20160423143914" - } -}