fix(core): update
This commit is contained in:
parent
8b85b6c8bc
commit
4cb6aa03e6
23
.gitignore
vendored
23
.gitignore
vendored
@ -1,5 +1,22 @@
|
|||||||
node_modules/
|
.nogit/
|
||||||
|
|
||||||
|
# artifacts
|
||||||
coverage/
|
coverage/
|
||||||
pages/
|
|
||||||
public/
|
public/
|
||||||
test/temp/
|
pages/
|
||||||
|
|
||||||
|
# installs
|
||||||
|
node_modules/
|
||||||
|
|
||||||
|
# caches
|
||||||
|
.yarn/
|
||||||
|
.cache/
|
||||||
|
.rpt2_cache
|
||||||
|
|
||||||
|
# builds
|
||||||
|
dist/
|
||||||
|
dist_web/
|
||||||
|
dist_serve/
|
||||||
|
dist_ts_web/
|
||||||
|
|
||||||
|
# custom
|
@ -1,5 +1,5 @@
|
|||||||
# gitzone standard
|
# gitzone ci_default
|
||||||
image: hosttoday/ht-docker-node:npmci
|
image: registry.gitlab.com/hosttoday/ht-docker-node:npmci
|
||||||
|
|
||||||
cache:
|
cache:
|
||||||
paths:
|
paths:
|
||||||
@ -26,6 +26,7 @@ mirror:
|
|||||||
snyk:
|
snyk:
|
||||||
stage: security
|
stage: security
|
||||||
script:
|
script:
|
||||||
|
- npmci npm prepare
|
||||||
- npmci command npm install -g snyk
|
- npmci command npm install -g snyk
|
||||||
- npmci command npm install --ignore-scripts
|
- npmci command npm install --ignore-scripts
|
||||||
- npmci command snyk test
|
- npmci command snyk test
|
||||||
@ -36,21 +37,11 @@ snyk:
|
|||||||
# ====================
|
# ====================
|
||||||
# test stage
|
# test stage
|
||||||
# ====================
|
# ====================
|
||||||
testLEGACY:
|
|
||||||
stage: test
|
|
||||||
script:
|
|
||||||
- npmci node install legacy
|
|
||||||
- npmci npm install
|
|
||||||
- npmci npm test
|
|
||||||
coverage: /\d+.?\d+?\%\s*coverage/
|
|
||||||
tags:
|
|
||||||
- docker
|
|
||||||
- notpriv
|
|
||||||
allow_failure: true
|
|
||||||
|
|
||||||
testLTS:
|
testLTS:
|
||||||
stage: test
|
stage: test
|
||||||
script:
|
script:
|
||||||
|
- npmci npm prepare
|
||||||
- npmci node install lts
|
- npmci node install lts
|
||||||
- npmci npm install
|
- npmci npm install
|
||||||
- npmci npm test
|
- npmci npm test
|
||||||
@ -59,12 +50,13 @@ testLTS:
|
|||||||
- docker
|
- docker
|
||||||
- notpriv
|
- notpriv
|
||||||
|
|
||||||
testSTABLE:
|
testBuild:
|
||||||
stage: test
|
stage: test
|
||||||
script:
|
script:
|
||||||
- npmci node install stable
|
- npmci npm prepare
|
||||||
|
- npmci node install lts
|
||||||
- npmci npm install
|
- npmci npm install
|
||||||
- npmci npm test
|
- npmci command npm run build
|
||||||
coverage: /\d+.?\d+?\%\s*coverage/
|
coverage: /\d+.?\d+?\%\s*coverage/
|
||||||
tags:
|
tags:
|
||||||
- docker
|
- docker
|
||||||
@ -73,7 +65,7 @@ testSTABLE:
|
|||||||
release:
|
release:
|
||||||
stage: release
|
stage: release
|
||||||
script:
|
script:
|
||||||
- npmci node install stable
|
- npmci node install lts
|
||||||
- npmci npm publish
|
- npmci npm publish
|
||||||
only:
|
only:
|
||||||
- tags
|
- tags
|
||||||
@ -86,19 +78,11 @@ release:
|
|||||||
# ====================
|
# ====================
|
||||||
codequality:
|
codequality:
|
||||||
stage: metadata
|
stage: metadata
|
||||||
image: docker:stable
|
|
||||||
allow_failure: true
|
allow_failure: true
|
||||||
services:
|
|
||||||
- docker:stable-dind
|
|
||||||
script:
|
script:
|
||||||
- export SP_VERSION=$(echo "$CI_SERVER_VERSION" | sed 's/^\([0-9]*\)\.\([0-9]*\).*/\1-\2-stable/')
|
- npmci command npm install -g tslint typescript
|
||||||
- docker run
|
- npmci npm install
|
||||||
--env SOURCE_CODE="$PWD"
|
- npmci command "tslint -c tslint.json ./ts/**/*.ts"
|
||||||
--volume "$PWD":/code
|
|
||||||
--volume /var/run/docker.sock:/var/run/docker.sock
|
|
||||||
"registry.gitlab.com/gitlab-org/security-products/codequality:$SP_VERSION" /code
|
|
||||||
artifacts:
|
|
||||||
paths: [codeclimate.json]
|
|
||||||
tags:
|
tags:
|
||||||
- docker
|
- docker
|
||||||
- priv
|
- priv
|
||||||
@ -117,9 +101,10 @@ pages:
|
|||||||
image: hosttoday/ht-docker-node:npmci
|
image: hosttoday/ht-docker-node:npmci
|
||||||
stage: metadata
|
stage: metadata
|
||||||
script:
|
script:
|
||||||
- npmci command npm install -g typedoc typescript
|
- npmci command npm install -g @gitzone/tsdoc
|
||||||
|
- npmci npm prepare
|
||||||
- npmci npm install
|
- npmci npm install
|
||||||
- npmci command typedoc --module "commonjs" --target "ES2016" --out public/ ts/
|
- npmci command tsdoc
|
||||||
tags:
|
tags:
|
||||||
- docker
|
- docker
|
||||||
- notpriv
|
- notpriv
|
||||||
@ -130,13 +115,3 @@ pages:
|
|||||||
paths:
|
paths:
|
||||||
- public
|
- public
|
||||||
allow_failure: true
|
allow_failure: true
|
||||||
|
|
||||||
windowsCompatibility:
|
|
||||||
image: stefanscherer/node-windows:10-build-tools
|
|
||||||
stage: metadata
|
|
||||||
script:
|
|
||||||
- npm install & npm test
|
|
||||||
coverage: /\d+.?\d+?\%\s*coverage/
|
|
||||||
tags:
|
|
||||||
- windows
|
|
||||||
allow_failure: true
|
|
||||||
|
@ -1,5 +0,0 @@
|
|||||||
FROM hosttoday/ht-docker-node:npmts
|
|
||||||
COPY ./ /node-app
|
|
||||||
WORKDIR /node-app
|
|
||||||
RUN npm install
|
|
||||||
RUN npm test
|
|
36
README.md
36
README.md
@ -1,27 +1,20 @@
|
|||||||
# smartssh
|
# @pushrocks/smartssh
|
||||||
|
|
||||||
setups SSH quickly and in a painless manner
|
setups SSH quickly and in a painless manner
|
||||||
|
|
||||||
> Attention: This is still alpha, so some things won't work, not all things are implemented.
|
## Availabililty and Links
|
||||||
|
* [npmjs.org (npm package)](https://www.npmjs.com/package/@pushrocks/smartssh)
|
||||||
## Availabililty
|
* [gitlab.com (source)](https://gitlab.com/pushrocks/smartssh)
|
||||||
|
* [github.com (source mirror)](https://github.com/pushrocks/smartssh)
|
||||||
[![npm](https://push.rocks/assets/repo-button-npm.svg)](https://www.npmjs.com/package/smartssh)
|
* [docs (typedoc)](https://pushrocks.gitlab.io/smartssh/)
|
||||||
[![git](https://push.rocks/assets/repo-button-git.svg)](https://gitlab.com/pushrocks/smartssh)
|
|
||||||
[![git](https://push.rocks/assets/repo-button-mirror.svg)](https://github.com/pushrocks/smartssh)
|
|
||||||
[![docs](https://push.rocks/assets/repo-button-docs.svg)](https://pushrocks.gitlab.io/smartssh/)
|
|
||||||
|
|
||||||
## Status for master
|
## Status for master
|
||||||
|
|
||||||
[![build status](https://gitlab.com/pushrocks/smartssh/badges/master/build.svg)](https://gitlab.com/pushrocks/smartssh/commits/master)
|
[![build status](https://gitlab.com/pushrocks/smartssh/badges/master/build.svg)](https://gitlab.com/pushrocks/smartssh/commits/master)
|
||||||
[![coverage report](https://gitlab.com/pushrocks/smartssh/badges/master/coverage.svg)](https://gitlab.com/pushrocks/smartssh/commits/master)
|
[![coverage report](https://gitlab.com/pushrocks/smartssh/badges/master/coverage.svg)](https://gitlab.com/pushrocks/smartssh/commits/master)
|
||||||
[![npm downloads per month](https://img.shields.io/npm/dm/smartssh.svg)](https://www.npmjs.com/package/smartssh)
|
[![npm downloads per month](https://img.shields.io/npm/dm/@pushrocks/smartssh.svg)](https://www.npmjs.com/package/@pushrocks/smartssh)
|
||||||
[![Dependency Status](https://david-dm.org/pushrocks/smartssh.svg)](https://david-dm.org/pushrocks/smartssh)
|
[![Known Vulnerabilities](https://snyk.io/test/npm/@pushrocks/smartssh/badge.svg)](https://snyk.io/test/npm/@pushrocks/smartssh)
|
||||||
[![bitHound Dependencies](https://www.bithound.io/github/pushrocks/smartssh/badges/dependencies.svg)](https://www.bithound.io/github/pushrocks/smartssh/master/dependencies/npm)
|
[![TypeScript](https://img.shields.io/badge/TypeScript->=%203.x-blue.svg)](https://nodejs.org/dist/latest-v10.x/docs/api/)
|
||||||
[![bitHound Code](https://www.bithound.io/github/pushrocks/smartssh/badges/code.svg)](https://www.bithound.io/github/pushrocks/smartssh)
|
[![node](https://img.shields.io/badge/node->=%2010.x.x-blue.svg)](https://nodejs.org/dist/latest-v10.x/docs/api/)
|
||||||
[![TypeScript](https://img.shields.io/badge/TypeScript-2.x-blue.svg)](https://nodejs.org/dist/latest-v6.x/docs/api/)
|
[![JavaScript Style Guide](https://img.shields.io/badge/code%20style-prettier-ff69b4.svg)](https://prettier.io/)
|
||||||
[![node](https://img.shields.io/badge/node->=%206.x.x-blue.svg)](https://nodejs.org/dist/latest-v6.x/docs/api/)
|
|
||||||
[![JavaScript Style Guide](https://img.shields.io/badge/code%20style-standard-brightgreen.svg)](http://standardjs.com/)
|
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
@ -55,4 +48,9 @@ sshInstance.getKey({
|
|||||||
sshInstance.getKeys(); // returns array of all available getKeys. Each key is in form of class sshKey
|
sshInstance.getKeys(); // returns array of all available getKeys. Each key is in form of class sshKey
|
||||||
```
|
```
|
||||||
|
|
||||||
[![npm](https://push.rocks/assets/repo-header.svg)](https://push.rocks)
|
For further information read the linked docs at the top of this readme.
|
||||||
|
|
||||||
|
> MIT licensed | **©** [Lossless GmbH](https://lossless.gmbh)
|
||||||
|
| By using this npm module you agree to our [privacy policy](https://lossless.gmbH/privacy.html)
|
||||||
|
|
||||||
|
[![repo-footer](https://pushrocks.gitlab.io/assets/repo-footer.svg)](https://maintainedby.lossless.com)
|
||||||
|
@ -2,5 +2,15 @@
|
|||||||
"npmci": {
|
"npmci": {
|
||||||
"npmGlobalTools": [],
|
"npmGlobalTools": [],
|
||||||
"npmAccessLevel": "public"
|
"npmAccessLevel": "public"
|
||||||
|
},
|
||||||
|
"gitzone": {
|
||||||
|
"module": {
|
||||||
|
"githost": "gitlab.com",
|
||||||
|
"gitscope": "pushrocks",
|
||||||
|
"gitrepo": "smartssh",
|
||||||
|
"shortDescription": "setups SSH quickly and in a painless manner",
|
||||||
|
"npmPackagename": "@pushrocks/smartssh",
|
||||||
|
"license": "MIT"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
1678
package-lock.json
generated
1678
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
37
package.json
37
package.json
@ -7,7 +7,7 @@
|
|||||||
"typings": "dist/index.d.ts",
|
"typings": "dist/index.d.ts",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test": "(tstest test/)",
|
"test": "(tstest test/)",
|
||||||
"testDocker": "npmdocker",
|
"testDocker": "tsdocker",
|
||||||
"build": "(tsbuild)"
|
"build": "(tsbuild)"
|
||||||
},
|
},
|
||||||
"repository": {
|
"repository": {
|
||||||
@ -26,21 +26,32 @@
|
|||||||
},
|
},
|
||||||
"homepage": "https://gitlab.com/pushrocks/smartssh#readme",
|
"homepage": "https://gitlab.com/pushrocks/smartssh#readme",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@pushrocks/smartfile": "^6.0.8",
|
"@pushrocks/smartfile": "^7.0.4",
|
||||||
"@pushrocks/smartpath": "^4.0.1",
|
"@pushrocks/smartpath": "^4.0.1",
|
||||||
"@pushrocks/smartpromise": "^2.0.5",
|
"@pushrocks/smartpromise": "^3.0.2",
|
||||||
"@pushrocks/smartshell": "^2.0.6",
|
"@pushrocks/smartshell": "^2.0.23",
|
||||||
"@pushrocks/smartstring": "^3.0.4",
|
"@pushrocks/smartstring": "^3.0.10",
|
||||||
"@types/fs-extra": "^5.0.4",
|
"@types/fs-extra": "^8.0.0",
|
||||||
"@types/minimatch": "^3.0.3",
|
"@types/minimatch": "^3.0.3",
|
||||||
"fs-extra": "^7.0.0",
|
"fs-extra": "^8.1.0",
|
||||||
"minimatch": "^3.0.4"
|
"minimatch": "^3.0.4"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@gitzone/tsbuild": "^2.0.22",
|
"@gitzone/tsbuild": "^2.1.11",
|
||||||
"@gitzone/tsrun": "^1.1.12",
|
"@gitzone/tsdocker": "^1.2.39",
|
||||||
"@gitzone/tstest": "^1.0.15",
|
"@gitzone/tsrun": "^1.2.6",
|
||||||
"@pushrocks/tapbundle": "^3.0.7",
|
"@gitzone/tstest": "^1.0.24",
|
||||||
"@types/node": "^10.10.1"
|
"@pushrocks/tapbundle": "^3.0.11",
|
||||||
}
|
"@types/node": "^12.6.6"
|
||||||
|
},
|
||||||
|
"files": [
|
||||||
|
"ts/*",
|
||||||
|
"ts_web/*",
|
||||||
|
"dist/*",
|
||||||
|
"dist_web/*",
|
||||||
|
"assets/*",
|
||||||
|
"cli.js",
|
||||||
|
"npmextra.json",
|
||||||
|
"readme.md"
|
||||||
|
]
|
||||||
}
|
}
|
1
test/temp/bitbucket.org
Normal file
1
test/temp/bitbucket.org
Normal file
@ -0,0 +1 @@
|
|||||||
|
somePrivateKey
|
1
test/temp/bitbucket.org.pub
Normal file
1
test/temp/bitbucket.org.pub
Normal file
@ -0,0 +1 @@
|
|||||||
|
somePublicKey
|
15
test/temp/config
Normal file
15
test/temp/config
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
Host gitlab.com
|
||||||
|
HostName gitlab.com
|
||||||
|
IdentityFile ~/.ssh/gitlab.com
|
||||||
|
StrictHostKeyChecking no
|
||||||
|
|
||||||
|
Host bitbucket.org
|
||||||
|
HostName bitbucket.org
|
||||||
|
IdentityFile ~/.ssh/bitbucket.org
|
||||||
|
StrictHostKeyChecking no
|
||||||
|
|
||||||
|
Host github.com
|
||||||
|
HostName github.com
|
||||||
|
IdentityFile ~/.ssh/github.com
|
||||||
|
StrictHostKeyChecking no
|
||||||
|
|
1
test/temp/example.com
Normal file
1
test/temp/example.com
Normal file
@ -0,0 +1 @@
|
|||||||
|
someExamplePrivateKey
|
1
test/temp/example.com.pub
Normal file
1
test/temp/example.com.pub
Normal file
@ -0,0 +1 @@
|
|||||||
|
someExamplePublicKey
|
1
test/temp/github.com
Normal file
1
test/temp/github.com
Normal file
@ -0,0 +1 @@
|
|||||||
|
someGitHubPrivateKey
|
1
test/temp/github.com.pub
Normal file
1
test/temp/github.com.pub
Normal file
@ -0,0 +1 @@
|
|||||||
|
someGitHubPublicKey
|
1
test/temp/gitlab.com
Normal file
1
test/temp/gitlab.com
Normal file
@ -0,0 +1 @@
|
|||||||
|
somePrivateKey
|
1
test/temp/gitlab.com.pub
Normal file
1
test/temp/gitlab.com.pub
Normal file
@ -0,0 +1 @@
|
|||||||
|
somePublicKey
|
@ -12,7 +12,7 @@ export class SshConfig {
|
|||||||
* stores a config file
|
* stores a config file
|
||||||
*/
|
*/
|
||||||
store(dirPathArg: string) {
|
store(dirPathArg: string) {
|
||||||
let done = plugins.q.defer();
|
let done = plugins.smartpromise.defer();
|
||||||
let configArray: configObject[] = [];
|
let configArray: configObject[] = [];
|
||||||
let configString;
|
let configString;
|
||||||
for (let key in this._sshKeyArray) {
|
for (let key in this._sshKeyArray) {
|
||||||
@ -45,7 +45,7 @@ export class SshConfig {
|
|||||||
return done.promise;
|
return done.promise;
|
||||||
}
|
}
|
||||||
read(dirPathArg) {
|
read(dirPathArg) {
|
||||||
let done = plugins.q.defer();
|
let done = plugins.smartpromise.defer();
|
||||||
let configArray: configObject[];
|
let configArray: configObject[];
|
||||||
plugins.smartfile.fs.toStringSync(plugins.path.join(dirPathArg, 'config'));
|
plugins.smartfile.fs.toStringSync(plugins.path.join(dirPathArg, 'config'));
|
||||||
|
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
import * as fs from 'fs-extra';
|
import * as fs from 'fs-extra';
|
||||||
import * as minimatch from 'minimatch';
|
import * as minimatch from 'minimatch';
|
||||||
import * as path from 'path';
|
import * as path from 'path';
|
||||||
import * as q from '@pushrocks/smartpromise';
|
import * as smartpromise from '@pushrocks/smartpromise';
|
||||||
import * as shelljs from '@pushrocks/smartshell';
|
import * as shelljs from '@pushrocks/smartshell';
|
||||||
import * as smartfile from '@pushrocks/smartfile';
|
import * as smartfile from '@pushrocks/smartfile';
|
||||||
import * as smartpath from '@pushrocks/smartpath';
|
import * as smartpath from '@pushrocks/smartpath';
|
||||||
import * as smartstring from '@pushrocks/smartstring';
|
import * as smartstring from '@pushrocks/smartstring';
|
||||||
|
|
||||||
export { fs, minimatch, path, q, shelljs, smartfile, smartpath, smartstring };
|
export { fs, minimatch, path, smartpromise, shelljs, smartfile, smartpath, smartstring };
|
||||||
|
16
tslint.json
16
tslint.json
@ -1,3 +1,17 @@
|
|||||||
{
|
{
|
||||||
"extends": "tslint-config-standard"
|
"extends": ["tslint:latest", "tslint-config-prettier"],
|
||||||
|
"rules": {
|
||||||
|
"semicolon": [true, "always"],
|
||||||
|
"no-console": false,
|
||||||
|
"ordered-imports": false,
|
||||||
|
"object-literal-sort-keys": false,
|
||||||
|
"member-ordering": {
|
||||||
|
"options":{
|
||||||
|
"order": [
|
||||||
|
"static-method"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"defaultSeverity": "warning"
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user