fix(core): update

This commit is contained in:
Philipp Kunz 2019-08-22 00:20:10 +02:00
parent 4e5ddf8411
commit 32bd229f91
5 changed files with 104 additions and 75 deletions

View File

@ -1,5 +1,7 @@
# gitzone ci_default # gitzone ci_default
image: hosttoday/ht-docker-node:npmci image: registry.gitlab.com/hosttoday/ht-docker-node:npmci
variables:
GIT_STRATEGY: clone
cache: cache:
paths: paths:
@ -48,15 +50,15 @@ testLTS:
coverage: /\d+.?\d+?\%\s*coverage/ coverage: /\d+.?\d+?\%\s*coverage/
tags: tags:
- docker - docker
- notpriv - priv
testSTABLE: testBuild:
stage: test stage: test
script: script:
- npmci npm prepare - npmci npm prepare
- npmci node install stable - 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
@ -65,7 +67,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
@ -98,7 +100,9 @@ trigger:
- notpriv - notpriv
pages: pages:
image: hosttoday/ht-docker-node:npmci image: hosttoday/ht-docker-dbase:npmci
services:
- docker:18-dind
stage: metadata stage: metadata
script: script:
- npmci command npm install -g @gitzone/tsdoc - npmci command npm install -g @gitzone/tsdoc

View File

@ -23,6 +23,6 @@ Use TypeScript for best in class instellisense.
For further information read the linked docs at the top of this readme. For further information read the linked docs at the top of this readme.
> MIT licensed | **©** [Lossless GmbH](https://lossless.gmbh) > MIT licensed | **©** [Lossless GmbH](https://lossless.gmbh)
| By using this npm module you agree to our [privacy policy](https://lossless.gmbH/privacy.html) | By using this npm module you agree to our [privacy policy](https://lossless.gmbH/privacy)
[![repo-footer](https://pushrocks.gitlab.io/assets/repo-footer.svg)](https://maintainedby.lossless.com) [![repo-footer](https://lossless.gitlab.io/publicrelations/repofooter.svg)](https://maintainedby.lossless.com)

116
package-lock.json generated
View File

@ -15,18 +15,18 @@
} }
}, },
"@babel/code-frame": { "@babel/code-frame": {
"version": "7.0.0", "version": "7.5.5",
"resolved": "https://verdaccio.lossless.one/@babel%2fcode-frame/-/code-frame-7.0.0.tgz", "resolved": "https://verdaccio.lossless.one/@babel%2fcode-frame/-/code-frame-7.5.5.tgz",
"integrity": "sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA==", "integrity": "sha512-27d4lZoomVyo51VegxI20xZPuSHusqbQag/ztrBC7wegWoQ1nLREPVSKSW8byhTlzTKyNE4ifaTA6lCp7JjpFw==",
"dev": true, "dev": true,
"requires": { "requires": {
"@babel/highlight": "^7.0.0" "@babel/highlight": "^7.0.0"
} }
}, },
"@babel/highlight": { "@babel/highlight": {
"version": "7.0.0", "version": "7.5.0",
"resolved": "https://verdaccio.lossless.one/@babel%2fhighlight/-/highlight-7.0.0.tgz", "resolved": "https://verdaccio.lossless.one/@babel%2fhighlight/-/highlight-7.5.0.tgz",
"integrity": "sha512-UFMC4ZeFC48Tpvj7C8UgLvtkaUuovQX+5xNWrsIoMG8o2z+XFKjKaN9iVmS84dPwVN00W4wPmqvYoZF3EGAsfw==", "integrity": "sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"chalk": "^2.0.0", "chalk": "^2.0.0",
@ -49,15 +49,39 @@
} }
}, },
"@gitzone/tsrun": { "@gitzone/tsrun": {
"version": "1.2.6", "version": "1.2.8",
"resolved": "https://verdaccio.lossless.one/@gitzone%2ftsrun/-/tsrun-1.2.6.tgz", "resolved": "https://verdaccio.lossless.one/@gitzone%2ftsrun/-/tsrun-1.2.8.tgz",
"integrity": "sha512-MTgQ7OiKfMpRQRumJp8aGuLCNNyWGjZSxsF+GfZ7cmg2DUtJRyCL0Ybkai1sPdMWG/zE8RUo50WvBKEChdVyvA==", "integrity": "sha512-G65DNcjegxF6w/O9MYD2mlHh+QVUiLuZvgLD5eamOOuWLhzuiE1tDzv5praJ/woJQzzZinDs+IyRyZ5rWKp/fQ==",
"dev": true, "dev": true,
"requires": { "requires": {
"@gitzone/tsbuild": "^2.1.8", "@pushrocks/smartfile": "^7.0.4",
"@pushrocks/smartfile": "^7.0.2", "ts-node": "^8.3.0",
"ts-node": "^8.0.3", "typescript": "^3.5.3"
"typescript": "^3.4.2" },
"dependencies": {
"@pushrocks/smartfile": {
"version": "7.0.4",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartfile/-/smartfile-7.0.4.tgz",
"integrity": "sha512-ym8eigWJAQhwgmuVLew3GLrk4WhV03ajapwuMWytxKSzfIW9ZqceJBX2QzOkmhFGA2bp+gc4Q2wOBy3Ffnlj+A==",
"dev": true,
"requires": {
"@pushrocks/smartpath": "^4.0.1",
"@pushrocks/smartpromise": "^3.0.2",
"@pushrocks/smartrequest": "^1.1.14",
"@types/fs-extra": "^5.0.5",
"@types/vinyl": "^2.0.2",
"fs-extra": "^7.0.1",
"glob": "^7.1.3",
"js-yaml": "^3.13.1",
"vinyl-file": "^3.0.0"
}
},
"typescript": {
"version": "3.5.3",
"resolved": "https://verdaccio.lossless.one/typescript/-/typescript-3.5.3.tgz",
"integrity": "sha512-ACzBtm/PhXBDId6a6sDJfroT2pOWt/oOnk4/dElG5G33ZL776N3Y6/6bKZJBFpd+b05F3Ct9qDjMeJmRWtE2/g==",
"dev": true
}
} }
}, },
"@gitzone/tstest": { "@gitzone/tstest": {
@ -314,9 +338,9 @@
} }
}, },
"@pushrocks/tapbundle": { "@pushrocks/tapbundle": {
"version": "3.0.9", "version": "3.0.11",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2ftapbundle/-/tapbundle-3.0.9.tgz", "resolved": "https://verdaccio.lossless.one/@pushrocks%2ftapbundle/-/tapbundle-3.0.11.tgz",
"integrity": "sha512-+EMdP3iykAtx192sebHBAWCE+2RGUU7q9kp8iHe62H16WSbDDaDpnRNd6VHv389qTaZlubQb0d/FR+uQJUVUDQ==", "integrity": "sha512-s7epZfJZX+LsBVmIYvoaY4WtgPvRLnHZMVTpQAPJGMBqxJAQxhQ2wvGJjmqMAGhhznAHI6t4g+m0KTp3vFIRVg==",
"dev": true, "dev": true,
"requires": { "requires": {
"@pushrocks/early": "^3.0.3", "@pushrocks/early": "^3.0.3",
@ -327,24 +351,24 @@
} }
}, },
"@types/chai": { "@types/chai": {
"version": "4.1.7", "version": "4.2.0",
"resolved": "https://verdaccio.lossless.one/@types%2fchai/-/chai-4.1.7.tgz", "resolved": "https://verdaccio.lossless.one/@types%2fchai/-/chai-4.2.0.tgz",
"integrity": "sha512-2Y8uPt0/jwjhQ6EiluT0XCri1Dbplr0ZxfFXUz+ye13gaqE8u5gL5ppao1JrUYr9cIip5S6MvQzBS7Kke7U9VA==", "integrity": "sha512-zw8UvoBEImn392tLjxoavuonblX/4Yb9ha4KBU10FirCfwgzhKO0dvyJSF9ByxV1xK1r2AgnAi/tvQaLgxQqxA==",
"dev": true "dev": true
}, },
"@types/chai-as-promised": { "@types/chai-as-promised": {
"version": "7.1.0", "version": "7.1.2",
"resolved": "https://verdaccio.lossless.one/@types%2fchai-as-promised/-/chai-as-promised-7.1.0.tgz", "resolved": "https://verdaccio.lossless.one/@types%2fchai-as-promised/-/chai-as-promised-7.1.2.tgz",
"integrity": "sha512-MFiW54UOSt+f2bRw8J7LgQeIvE/9b4oGvwU7XW30S9QGAiHGnU/fmiOprsyMkdmH2rl8xSPc0/yrQw8juXU6bQ==", "integrity": "sha512-PO2gcfR3Oxa+u0QvECLe1xKXOqYTzCmWf0FhLhjREoW3fPAVamjihL7v1MOVLJLsnAMdLcjkfrs01yvDMwVK4Q==",
"dev": true, "dev": true,
"requires": { "requires": {
"@types/chai": "*" "@types/chai": "*"
} }
}, },
"@types/chai-string": { "@types/chai-string": {
"version": "1.4.1", "version": "1.4.2",
"resolved": "https://verdaccio.lossless.one/@types%2fchai-string/-/chai-string-1.4.1.tgz", "resolved": "https://verdaccio.lossless.one/@types%2fchai-string/-/chai-string-1.4.2.tgz",
"integrity": "sha512-aRNMs6TKgjgPlCHwDfq/YNy5VtRR2hJ4AUWByddrT0TRVVD8eX4MiHW6/iHvmQHRlVuuPZcwnTUE7b4yFt7bEA==", "integrity": "sha512-ld/1hV5qcPRGuwlPdvRfvM3Ka/iofOk2pH4VkasK4b1JJP1LjNmWWn0LsISf6RRzyhVOvs93rb9tM09e+UuF8Q==",
"dev": true, "dev": true,
"requires": { "requires": {
"@types/chai": "*" "@types/chai": "*"
@ -400,9 +424,9 @@
"dev": true "dev": true
}, },
"@types/node": { "@types/node": {
"version": "12.0.8", "version": "12.7.2",
"resolved": "https://verdaccio.lossless.one/@types%2fnode/-/node-12.0.8.tgz", "resolved": "https://verdaccio.lossless.one/@types%2fnode/-/node-12.7.2.tgz",
"integrity": "sha512-b8bbUOTwzIY3V5vDTY1fIJ+ePKDUBqt2hC2woVGotdQQhG/2Sh62HOKHrT7ab+VerXAcPyAiTEipPu/FsreUtg==" "integrity": "sha512-dyYO+f6ihZEtNPDcWNR1fkoTDf3zAK3lAABDze3mz6POyIercH0lEUawUFXlG8xaQZmm1yEBON/4TsYv/laDYg=="
}, },
"@types/npm": { "@types/npm": {
"version": "2.0.30", "version": "2.0.30",
@ -456,9 +480,9 @@
} }
}, },
"arg": { "arg": {
"version": "4.1.0", "version": "4.1.1",
"resolved": "https://verdaccio.lossless.one/arg/-/arg-4.1.0.tgz", "resolved": "https://verdaccio.lossless.one/arg/-/arg-4.1.1.tgz",
"integrity": "sha512-ZWc51jO3qegGkVh8Hwpv636EkbesNV5ZNQPCtRa+0qytRYPEs9IYT9qITY9buezqUH5uqyzlWLcufrzU2rffdg==", "integrity": "sha512-SlmP3fEA88MBv0PypnXZ8ZfJhwmDeIE3SP71j37AiXQBXYosPV0x6uISAaHYSlSVhmHOVkomen0tbGk6Anlebw==",
"dev": true "dev": true
}, },
"argparse": { "argparse": {
@ -765,9 +789,9 @@
"dev": true "dev": true
}, },
"esutils": { "esutils": {
"version": "2.0.2", "version": "2.0.3",
"resolved": "https://verdaccio.lossless.one/esutils/-/esutils-2.0.2.tgz", "resolved": "https://verdaccio.lossless.one/esutils/-/esutils-2.0.3.tgz",
"integrity": "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs=", "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==",
"dev": true "dev": true
}, },
"execa": { "execa": {
@ -1356,9 +1380,9 @@
"dev": true "dev": true
}, },
"resolve": { "resolve": {
"version": "1.11.1", "version": "1.12.0",
"resolved": "https://verdaccio.lossless.one/resolve/-/resolve-1.11.1.tgz", "resolved": "https://verdaccio.lossless.one/resolve/-/resolve-1.12.0.tgz",
"integrity": "sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw==", "integrity": "sha512-B/dOmuoAik5bKcD6s6nXDCjzUKnaDvdkRyAk6rsmsKLipWj4797iothd7jmmUhWTfinVMU+wc56rYKsit2Qy4w==",
"dev": true, "dev": true,
"requires": { "requires": {
"path-parse": "^1.0.6" "path-parse": "^1.0.6"
@ -1443,9 +1467,9 @@
"dev": true "dev": true
}, },
"source-map-support": { "source-map-support": {
"version": "0.5.12", "version": "0.5.13",
"resolved": "https://verdaccio.lossless.one/source-map-support/-/source-map-support-0.5.12.tgz", "resolved": "https://verdaccio.lossless.one/source-map-support/-/source-map-support-0.5.13.tgz",
"integrity": "sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ==", "integrity": "sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w==",
"dev": true, "dev": true,
"requires": { "requires": {
"buffer-from": "^1.0.0", "buffer-from": "^1.0.0",
@ -1555,9 +1579,9 @@
"dev": true "dev": true
}, },
"tslint": { "tslint": {
"version": "5.17.0", "version": "5.19.0",
"resolved": "https://verdaccio.lossless.one/tslint/-/tslint-5.17.0.tgz", "resolved": "https://verdaccio.lossless.one/tslint/-/tslint-5.19.0.tgz",
"integrity": "sha512-pflx87WfVoYepTet3xLfDOLDm9Jqi61UXIKePOuca0qoAZyrGWonDG9VTbji58Fy+8gciUn8Bt7y69+KEVjc/w==", "integrity": "sha512-1LwwtBxfRJZnUvoS9c0uj8XQtAnyhWr9KlNvDIdB+oXyT+VpsOAaEhEgKi1HrZ8rq0ki/AAnbGSv4KM6/AfVZw==",
"dev": true, "dev": true,
"requires": { "requires": {
"@babel/code-frame": "^7.0.0", "@babel/code-frame": "^7.0.0",
@ -1763,9 +1787,9 @@
} }
}, },
"yn": { "yn": {
"version": "3.1.0", "version": "3.1.1",
"resolved": "https://verdaccio.lossless.one/yn/-/yn-3.1.0.tgz", "resolved": "https://verdaccio.lossless.one/yn/-/yn-3.1.1.tgz",
"integrity": "sha512-kKfnnYkbTfrAdd0xICNFw7Atm8nKpLcLv9AZGEt+kczL/WQVai4e2V6ZN8U/O+iI6WrNuJjNNOyu4zfhl9D3Hg==", "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==",
"dev": true "dev": true
} }
} }

View File

@ -25,15 +25,15 @@
"dependencies": { "dependencies": {
"@pushrocks/smartparam": "^1.0.4", "@pushrocks/smartparam": "^1.0.4",
"@pushrocks/smartpromise": "^3.0.2", "@pushrocks/smartpromise": "^3.0.2",
"@types/node": "^12.0.8" "@types/node": "^12.7.2"
}, },
"devDependencies": { "devDependencies": {
"@gitzone/tsbuild": "^2.1.11", "@gitzone/tsbuild": "^2.1.11",
"@gitzone/tsrun": "^1.2.6", "@gitzone/tsrun": "^1.2.8",
"@gitzone/tstest": "^1.0.24", "@gitzone/tstest": "^1.0.24",
"@pushrocks/tapbundle": "^3.0.9", "@pushrocks/tapbundle": "^3.0.11",
"@types/npm": "^2.0.29", "@types/npm": "^2.0.29",
"tslint": "^5.17.0", "tslint": "^5.19.0",
"tslint-config-prettier": "^1.18.0" "tslint-config-prettier": "^1.18.0"
}, },
"private": false, "private": false,
@ -42,9 +42,10 @@
"ts_web/*", "ts_web/*",
"dist/*", "dist/*",
"dist_web/*", "dist_web/*",
"dist_ts_web/*",
"assets/*", "assets/*",
"cli.js", "cli.js",
"npmextra.json", "npmextra.json",
"readme.md" "readme.md"
] ]
} }

View File

@ -11,7 +11,7 @@ export interface IEnvObject {
* Smartenv class that makes it easy * Smartenv class that makes it easy
*/ */
export class Smartenv { export class Smartenv {
get runtimeEnv() { public get runtimeEnv() {
if (typeof window !== 'undefined') { if (typeof window !== 'undefined') {
return 'browser'; return 'browser';
} else if (typeof process !== 'undefined') { } else if (typeof process !== 'undefined') {
@ -19,11 +19,11 @@ export class Smartenv {
} }
} }
get isBrowser(): boolean { public get isBrowser(): boolean {
return !this.isNode; return !this.isNode;
} }
get userAgent(): string { public get userAgent(): string {
if (this.isBrowser) { if (this.isBrowser) {
// make sure we are in Browser // make sure we are in Browser
return navigator.userAgent; return navigator.userAgent;
@ -32,15 +32,15 @@ export class Smartenv {
} }
} }
get isNode(): boolean { public get isNode(): boolean {
return this.runtimeEnv === 'node'; return this.runtimeEnv === 'node';
} }
get nodeVersion(): string { public get nodeVersion(): string {
return process.version; return process.version;
} }
get isCI(): boolean { public get isCI(): boolean {
if (this.isNode) { if (this.isNode) {
if (process.env.CI) { if (process.env.CI) {
return true; return true;
@ -52,27 +52,27 @@ export class Smartenv {
} }
} }
async isMacAsync(): Promise<boolean> { public async isMacAsync(): Promise<boolean> {
if (this.isNode) { if (this.isNode) {
let os = await import('os'); const os = await import('os');
return os.platform() === 'darwin'; return os.platform() === 'darwin';
} else { } else {
return false; return false;
} }
} }
async isWindowsAsync(): Promise<boolean> { public async isWindowsAsync(): Promise<boolean> {
if (this.isNode) { if (this.isNode) {
let os = await import('os'); const os = await import('os');
return os.platform() === 'win32'; return os.platform() === 'win32';
} else { } else {
return false; return false;
} }
} }
async isLinuxAsync(): Promise<boolean> { public async isLinuxAsync(): Promise<boolean> {
if (this.isNode) { if (this.isNode) {
let os = await import('os'); const os = await import('os');
return os.platform() === 'linux'; return os.platform() === 'linux';
} else { } else {
return false; return false;
@ -90,10 +90,10 @@ export class Smartenv {
/** /**
* prints the environment to console * prints the environment to console
*/ */
async printEnv() { public async printEnv() {
if (this.isNode) { if (this.isNode) {
console.log('running on NODE'); console.log('running on NODE');
let smartenvVersion = require('../package.json').version; const smartenvVersion = require('../package.json').version;
console.log( console.log(
'node version is ' + this.nodeVersion + ' and smartenv version is ' + smartenvVersion 'node version is ' + this.nodeVersion + ' and smartenv version is ' + smartenvVersion
); );