From 044004701be1b0fd62dd3c9cefead594ebf27d5b Mon Sep 17 00:00:00 2001 From: Phil Kunz Date: Mon, 25 Apr 2016 05:06:39 +0200 Subject: [PATCH] added README --- README.md | 20 ++++++++++++++++++++ ts/smartssh.classes.ts | 6 +++--- 2 files changed, 23 insertions(+), 3 deletions(-) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..57ad7d1 --- /dev/null +++ b/README.md @@ -0,0 +1,20 @@ +# smartssh +setups SSH quickly and in a painless manner + +> Attention: This is still alpha, so some things won't work + +## Usage + +```javascript +var smartssh = require("smartssh"); +var sshInstance = new smartssh({ + sshDir: "/some/path/.ssh", // the standard ssh directory, optional, defaults to "~./.ssh" + sshSync: true // sync ssh this instance will represent the status of an ssh dir if set to true; +}); + +sshInstance.addKey({ + private: "somestring", + public: "somestring" +}); + +``` \ No newline at end of file diff --git a/ts/smartssh.classes.ts b/ts/smartssh.classes.ts index dbef45a..9edc2ea 100644 --- a/ts/smartssh.classes.ts +++ b/ts/smartssh.classes.ts @@ -5,13 +5,13 @@ import helpers = require("./smartssh.classes.helpers"); export class ssh { private sshDir:string; private sshKeys:sshKey[]; - private sync:boolean; // if set to true, the ssh dir will be kept in sync automatically - constructor(optionsArg:{sshDir?:string,sync?:boolean}={}){ + private sshSync:boolean; // if set to true, the ssh dir will be kept in sync automatically + constructor(optionsArg:{sshDir?:string,sshSync?:boolean}={}){ this.sshDir = optionsArg.sshDir this.sshDir ? this.sshKeys = helpers.sshKeyArrayFromDir(this.sshDir) : void(0); - this.sync = optionsArg.sync; + this.sshSync = optionsArg.sshSync; }; }