update structure
This commit is contained in:
parent
def368f8ab
commit
0454eef45f
5
dist/smartssh.classes.sshdir.js
vendored
5
dist/smartssh.classes.sshdir.js
vendored
@ -13,7 +13,6 @@ class SshDir {
|
|||||||
else {
|
else {
|
||||||
this._path = plugins.path.join(plugins.smartpath.get.home(), '.ssh/');
|
this._path = plugins.path.join(plugins.smartpath.get.home(), '.ssh/');
|
||||||
}
|
}
|
||||||
;
|
|
||||||
}
|
}
|
||||||
writeToDir(dirPathArg) {
|
writeToDir(dirPathArg) {
|
||||||
let path = this._path;
|
let path = this._path;
|
||||||
@ -24,7 +23,6 @@ class SshDir {
|
|||||||
});
|
});
|
||||||
this._sshConfig.store(path);
|
this._sshConfig.store(path);
|
||||||
}
|
}
|
||||||
;
|
|
||||||
readFromDir(dirPathArg) {
|
readFromDir(dirPathArg) {
|
||||||
let path = this._path;
|
let path = this._path;
|
||||||
if (dirPathArg)
|
if (dirPathArg)
|
||||||
@ -33,10 +31,9 @@ class SshDir {
|
|||||||
updateDirPath(dirPathArg) {
|
updateDirPath(dirPathArg) {
|
||||||
this._path = dirPathArg;
|
this._path = dirPathArg;
|
||||||
}
|
}
|
||||||
;
|
|
||||||
getKeys() {
|
getKeys() {
|
||||||
return helpers.sshKeyArrayFromDir(this._path);
|
return helpers.sshKeyArrayFromDir(this._path);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
exports.SshDir = SshDir;
|
exports.SshDir = SshDir;
|
||||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic21hcnRzc2guY2xhc3Nlcy5zc2hkaXIuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi90cy9zbWFydHNzaC5jbGFzc2VzLnNzaGRpci50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLDBCQUF1QjtBQUN2Qiw4Q0FBNkM7QUFDN0Msc0RBQXFEO0FBSXJEO0lBSUksWUFBWSxXQUFxQixFQUFDLFNBQW9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VUFBVSxDQUFDO1lBQUMsSUFBSSxHQUFHLFVBQVUsQ0FBQTtRQUNqQyxJQUFJLENBQUMsWUFBWSxDQUFDLE9BQU8sQ0FBQyxDQUFDLFNBQVM7WUFDbEMsU0FBUyxDQUFDLEtBQUssQ0FBQyxJQUFJLENBQUMsQ0FBQTtRQUN2QixDQUFDLENBQUMsQ0FBQTtRQUNGLElBQUksQ0FBQyxVQUFVLENBQUMsS0FBSyxDQUFDLElBQUksQ0FBQyxDQUFBO0lBQzdCLENBQUM7SUFFRCxXQUFXLENBQUUsVUFBbUI7UUFDOUIsSUFBSSxJQUFJLEdBQUcsSUFBSSxDQUFDLEtBQUssQ0FBQTtRQUNyQixFQUFFLENBQUMsQ0FBQyxVQUFVLENBQUM7WUFBQyxJQUFJLEdBQUcsVUFBVSxDQUFBO0lBQ25DLENBQUM7SUFDRCxhQUFhLENBQUUsVUFBa0I7UUFDL0IsSUFBSSxDQUFDLEtBQUssR0FBRyxVQUFVLENBQUE7SUFDekIsQ0FBQztJQUVELE9BQU87UUFDTCxNQUFNLENBQUMsT0FBTyxDQUFDLGtCQUFrQixDQUFDLElBQUksQ0FBQyxLQUFLLENBQUMsQ0FBQTtJQUMvQyxDQUFDO0NBQ0Y7QUFsQ0Qsd0JBa0NDIn0=
|
2
dist/smartssh.classes.sshinstance.js
vendored
2
dist/smartssh.classes.sshinstance.js
vendored
@ -96,4 +96,4 @@ class SshInstance {
|
|||||||
;
|
;
|
||||||
}
|
}
|
||||||
exports.SshInstance = SshInstance;
|
exports.SshInstance = SshInstance;
|
||||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic21hcnRzc2guY2xhc3Nlcy5zc2hpbnN0YW5jZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL3NtYXJ0c3NoLmNsYXNzZXMuc3NoaW5zdGFuY2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQ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SSxDQUFDLENBQUMsQ0FBQztZQUNqQyxJQUFJLENBQUMsT0FBTyxDQUFDLFVBQVUsQ0FBQyxVQUFVLENBQUMsQ0FBQTtRQUNyQyxDQUFDO1FBQUMsSUFBSSxDQUFDLENBQUM7WUFDTixNQUFNLElBQUksS0FBSyxDQUFDLHFEQUFxRCxDQUFDLENBQUE7UUFDeEUsQ0FBQztJQUNILENBQUM7SUFBQSxDQUFDO0NBQ0g7QUE5RkQsa0NBOEZDIn0=
|
@ -4,6 +4,7 @@ import * as helpers from './smartssh.classes.helpers'
|
|||||||
import { SshInstance } from './smartssh.classes.sshinstance'
|
import { SshInstance } from './smartssh.classes.sshinstance'
|
||||||
import { SshKey } from './smartssh.classes.sshkey'
|
import { SshKey } from './smartssh.classes.sshkey'
|
||||||
import { SshConfig } from './smartssh.classes.sshconfig'
|
import { SshConfig } from './smartssh.classes.sshconfig'
|
||||||
|
|
||||||
export class SshDir { // sshDir class -> NOT EXPORTED, ONLY FOR INTERNAL USE
|
export class SshDir { // sshDir class -> NOT EXPORTED, ONLY FOR INTERNAL USE
|
||||||
private _path: string // the path of the ssh directory
|
private _path: string // the path of the ssh directory
|
||||||
private _sshKeyArray: SshKey[]
|
private _sshKeyArray: SshKey[]
|
||||||
@ -15,8 +16,9 @@ export class SshDir { // sshDir class -> NOT EXPORTED, ONLY FOR INTERNAL USE
|
|||||||
this._path = sshDirPathArg
|
this._path = sshDirPathArg
|
||||||
} else {
|
} else {
|
||||||
this._path = plugins.path.join(plugins.smartpath.get.home(), '.ssh/')
|
this._path = plugins.path.join(plugins.smartpath.get.home(), '.ssh/')
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
writeToDir (dirPathArg?: string) { // syncs sshInstance to directory
|
writeToDir (dirPathArg?: string) { // syncs sshInstance to directory
|
||||||
let path = this._path
|
let path = this._path
|
||||||
if (dirPathArg) path = dirPathArg
|
if (dirPathArg) path = dirPathArg
|
||||||
@ -24,14 +26,16 @@ export class SshDir { // sshDir class -> NOT EXPORTED, ONLY FOR INTERNAL USE
|
|||||||
sshKeyArg.store(path)
|
sshKeyArg.store(path)
|
||||||
})
|
})
|
||||||
this._sshConfig.store(path)
|
this._sshConfig.store(path)
|
||||||
};
|
}
|
||||||
|
|
||||||
readFromDir (dirPathArg?: string) { // syncs sshInstance from directory
|
readFromDir (dirPathArg?: string) { // syncs sshInstance from directory
|
||||||
let path = this._path
|
let path = this._path
|
||||||
if (dirPathArg) path = dirPathArg
|
if (dirPathArg) path = dirPathArg
|
||||||
}
|
}
|
||||||
updateDirPath (dirPathArg: string) {
|
updateDirPath (dirPathArg: string) {
|
||||||
this._path = dirPathArg
|
this._path = dirPathArg
|
||||||
};
|
}
|
||||||
|
|
||||||
getKeys () {
|
getKeys () {
|
||||||
return helpers.sshKeyArrayFromDir(this._path)
|
return helpers.sshKeyArrayFromDir(this._path)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user