Compare commits

...

10 Commits

Author SHA1 Message Date
5722deb7a0 8.0.33 2018-05-03 12:57:29 +02:00
50d71dde67 update ci 2018-05-03 12:56:58 +02:00
13123e180d 8.0.32 2018-05-03 12:45:24 +02:00
b13db4184b update snyk security policy 2018-05-03 12:45:22 +02:00
19f6097ab9 8.0.31 2018-05-03 12:35:48 +02:00
34066d8a13 switch to seperate build/test commands to inrpove speed 2018-05-03 12:35:41 +02:00
df87337f4d 8.0.30 2018-04-09 01:28:46 +02:00
105e5c2ff0 fix npmextra.json 2018-04-09 01:26:14 +02:00
7115b699ba 8.0.29 2018-04-09 01:19:36 +02:00
8c7ac4c1d0 update snyk policy 2018-04-09 01:19:28 +02:00
15 changed files with 856 additions and 335 deletions

View File

@ -63,6 +63,7 @@ testSTABLE:
release: release:
stage: release stage: release
script: script:
- npmci node install stable
- npmci npm prepare - npmci npm prepare
- npmci npm publish - npmci npm publish
only: only:

111
.snyk Normal file
View File

@ -0,0 +1,111 @@
# Snyk (https://snyk.io) policy file, patches or ignores known vulnerabilities.
version: v1.12.0
# ignores vulnerabilities until expiry date; change duration by modifying expiry date
ignore:
'npm:debug:20170905':
- node-pre-gyp > tar-pack > debug:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > tar-pack > debug:
reason: None given
expires: '2018-05-08T23:12:05.487Z'
'npm:tough-cookie:20170905':
- node-pre-gyp > request > tough-cookie:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > request > tough-cookie:
reason: None given
expires: '2018-05-08T23:12:05.487Z'
'npm:hoek:20180212':
- boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- cryptiles > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- hawk > cryptiles > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- node-pre-gyp > hawk > cryptiles > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > hawk > cryptiles > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- node-pre-gyp > request > hawk > cryptiles > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > request > hawk > cryptiles > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- hawk > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- node-pre-gyp > hawk > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > hawk > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- node-pre-gyp > request > hawk > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > request > hawk > boom > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- hawk > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- node-pre-gyp > hawk > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > hawk > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- node-pre-gyp > request > hawk > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > request > hawk > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- hawk > sntp > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- node-pre-gyp > hawk > sntp > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > hawk > sntp > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- node-pre-gyp > request > hawk > sntp > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
- smartchok > chokidar > fsevents > node-pre-gyp > request > hawk > sntp > hoek:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
'npm:shelljs:20140723':
- tapbuffer > smartshell > shelljs:
reason: None given
expires: '2018-05-08T23:10:17.169Z'
'npm:atob:20180429':
- gulp-sourcemaps > css > source-map-resolve > atob:
reason: None given
expires: '2018-06-02T10:44:49.656Z'
- gulp-sourcemaps > @gulp-sourcemaps/identity-map > css > source-map-resolve > atob:
reason: None given
expires: '2018-06-02T10:44:49.656Z'
'npm:deep-extend:20180409':
- smartchok > chokidar > fsevents > node-pre-gyp > rc > deep-extend:
reason: None given
expires: '2018-06-02T10:44:49.656Z'
- deep-extend:
reason: None given
expires: '2018-06-02T10:44:49.656Z'
- node-pre-gyp > rc > deep-extend:
reason: None given
expires: '2018-06-02T10:44:49.656Z'
'npm:sshpk:20180409':
- smartchok > chokidar > fsevents > node-pre-gyp > request > http-signature > sshpk:
reason: None given
expires: '2018-06-02T10:44:49.656Z'
patch: {}

View File

@ -1,2 +1,6 @@
import { INpmtsConfig } from '../npmts.config'; import { INpmtsConfig } from '../npmts.config';
/**
* run this module
* @param configArg some config for how to run this module
*/
export declare let run: (configArg: INpmtsConfig) => Promise<INpmtsConfig>; export declare let run: (configArg: INpmtsConfig) => Promise<INpmtsConfig>;

View File

@ -93,6 +93,10 @@ let handleCoverageData = (configArg) => __awaiter(this, void 0, void 0, function
} }
return configArg; return configArg;
}); });
/**
* run this module
* @param configArg some config for how to run this module
*/
exports.run = function (configArg) { exports.run = function (configArg) {
let done = q.defer(); let done = q.defer();
let config = configArg; let config = configArg;

20
dist/npmts.cli.js vendored
View File

@ -52,14 +52,13 @@ exports.run = () => __awaiter(this, void 0, void 0, function* () {
yield plugins.smartupdate.standardHandler.check('npmts', npmtsProjectInfo.version, 'http://gitzone.gitlab.io/npmts/changelog.html'); yield plugins.smartupdate.standardHandler.check('npmts', npmtsProjectInfo.version, 'http://gitzone.gitlab.io/npmts/changelog.html');
plugins.beautylog.log('---------------------------------------------'); plugins.beautylog.log('---------------------------------------------');
let npmtsCli = new plugins.smartcli.Smartcli(); let npmtsCli = new plugins.smartcli.Smartcli();
// build
npmtsCli npmtsCli
.standardTask() .addCommand('build')
.then(argvArg => { .subscribe((argvArg) => __awaiter(this, void 0, void 0, function* () {
plugins.beautylog.info('npmts version: ' + npmtsProjectInfo.version);
return NpmtsConfig.run(argvArg);
})
.then((configArg) => {
let done = q.defer(); let done = q.defer();
plugins.beautylog.info('npmts version: ' + npmtsProjectInfo.version);
const configArg = yield NpmtsConfig.run(argvArg);
plugins.beautylog.ora.start('loading additional modules...'); plugins.beautylog.ora.start('loading additional modules...');
NpmtsMods.modCompile NpmtsMods.modCompile
.load() .load()
@ -93,13 +92,18 @@ exports.run = () => __awaiter(this, void 0, void 0, function* () {
.then(NpmtsWatch.run) .then(NpmtsWatch.run)
.then(NpmtsShip.run); .then(NpmtsShip.run);
return done.promise; return done.promise;
}) }), err => {
.catch(err => {
if (err instanceof Error) { if (err instanceof Error) {
console.log(err); console.log(err);
} }
}); });
// standard task
npmtsCli.standardTask().subscribe((argvArg) => __awaiter(this, void 0, void 0, function* () {
yield npmtsCli.trigger('build');
}));
// cli metadata
npmtsCli.addVersion(npmtsProjectInfo.version); npmtsCli.addVersion(npmtsProjectInfo.version);
// start parsing
npmtsCli.startParse(); npmtsCli.startParse();
return yield done.promise; return yield done.promise;
}); });

View File

@ -22,5 +22,5 @@ export interface INpmtsConfig {
coverageResult?: number; coverageResult?: number;
}; };
} }
export declare let run: (argvArg: any) => Promise<{}>; export declare let run: (argvArg: any) => Promise<INpmtsConfig>;
export declare let configPromise: Promise<INpmtsConfig>; export declare let configPromise: Promise<INpmtsConfig>;

View File

@ -5,7 +5,7 @@ import * as npmextra from 'npmextra';
import * as projectinfo from 'projectinfo'; import * as projectinfo from 'projectinfo';
import * as path from 'path'; import * as path from 'path';
import * as smartanalytics from 'smartanalytics'; import * as smartanalytics from 'smartanalytics';
import * as smartcli from 'smartcli'; import * as smartcli from '@pushrocks/smartcli';
import * as smarterror from 'smarterror'; import * as smarterror from 'smarterror';
import * as smartfile from 'smartfile'; import * as smartfile from 'smartfile';
import * as smartpath from 'smartpath'; import * as smartpath from 'smartpath';

View File

@ -14,7 +14,7 @@ const path = require("path");
exports.path = path; exports.path = path;
const smartanalytics = require("smartanalytics"); const smartanalytics = require("smartanalytics");
exports.smartanalytics = smartanalytics; exports.smartanalytics = smartanalytics;
const smartcli = require("smartcli"); const smartcli = require("@pushrocks/smartcli");
exports.smartcli = smartcli; exports.smartcli = smartcli;
const smarterror = require("smarterror"); const smarterror = require("smarterror");
exports.smarterror = smarterror; exports.smarterror = smarterror;

View File

@ -1,5 +1,5 @@
{ {
"npmci": { "npmci": {
"npmAccessLevell": "public" "npmAccessLevel": "public"
} }
} }

View File

@ -1,6 +1,6 @@
{ {
"name": "@gitzone/npmts", "name": "@gitzone/npmts",
"version": "8.0.28", "version": "8.0.33",
"description": "best practice npm TypeScript modules", "description": "best practice npm TypeScript modules",
"main": "dist/index.js", "main": "dist/index.js",
"bin": { "bin": {
@ -34,27 +34,27 @@
}, },
"homepage": "https://gitlab.com/gitzone/npmts#readme", "homepage": "https://gitlab.com/gitzone/npmts#readme",
"dependencies": { "dependencies": {
"@pushrocks/smartcli": "^3.0.0",
"@types/gulp-sourcemaps": "0.0.32", "@types/gulp-sourcemaps": "0.0.32",
"@types/minimatch": "^3.0.1", "@types/minimatch": "^3.0.1",
"@types/through2": "^2.0.33", "@types/through2": "^2.0.33",
"beautylog": "^6.1.10", "beautylog": "^6.1.10",
"depcheck": "^0.6.8", "depcheck": "^0.6.9",
"early": "^2.1.1", "early": "^2.1.1",
"gulp-function": "^2.2.9", "gulp-function": "^2.2.9",
"gulp-sourcemaps": "^2.6.1", "gulp-sourcemaps": "^2.6.1",
"gulp-typescript": "^4.0.1", "gulp-typescript": "^4.0.2",
"lodash": "^4.17.4", "lodash": "^4.17.10",
"npmextra": "^2.0.9", "npmextra": "^2.0.9",
"projectinfo": "^3.0.4", "projectinfo": "^3.0.4",
"smartanalytics": "^2.0.9", "smartanalytics": "^2.0.9",
"smartchok": "^1.0.11", "smartchok": "1.0.14",
"smartcli": "^2.0.9",
"smartcov": "^1.0.2", "smartcov": "^1.0.2",
"smarterror": "^1.0.3", "smarterror": "^1.0.3",
"smartfile": "^4.2.26", "smartfile": "^4.2.26",
"smartgulp": "^1.0.6", "smartgulp": "^1.0.6",
"smartpath": "^3.2.8", "smartpath": "^3.2.8",
"smartq": "^1.1.6", "smartq": "^1.1.8",
"smartstream": "^1.0.10", "smartstream": "^1.0.10",
"smartstring": "^2.0.28", "smartstring": "^2.0.28",
"smartsystem": "^2.0.2", "smartsystem": "^2.0.2",
@ -62,9 +62,9 @@
"tapbuffer": "^1.0.31", "tapbuffer": "^1.0.31",
"through2": "^2.0.3", "through2": "^2.0.3",
"tsn": "^2.0.15", "tsn": "^2.0.15",
"typescript": "^2.6.2" "typescript": "^2.8.3"
}, },
"devDependencies": { "devDependencies": {
"@types/node": "^9.4.6" "@types/node": "^10.0.3"
} }
} }

View File

@ -108,6 +108,10 @@ let handleCoverageData = async (configArg: INpmtsConfig) => {
return configArg; return configArg;
}; };
/**
* run this module
* @param configArg some config for how to run this module
*/
export let run = function(configArg: INpmtsConfig) { export let run = function(configArg: INpmtsConfig) {
let done = q.defer<INpmtsConfig>(); let done = q.defer<INpmtsConfig>();
let config = configArg; let config = configArg;

View File

@ -51,14 +51,15 @@ export let run = async () => {
); );
plugins.beautylog.log('---------------------------------------------'); plugins.beautylog.log('---------------------------------------------');
let npmtsCli = new plugins.smartcli.Smartcli(); let npmtsCli = new plugins.smartcli.Smartcli();
// build
npmtsCli npmtsCli
.standardTask() .addCommand('build')
.then(argvArg => { .subscribe(async (argvArg) => {
plugins.beautylog.info('npmts version: ' + npmtsProjectInfo.version);
return NpmtsConfig.run(argvArg);
})
.then((configArg: NpmtsConfig.INpmtsConfig) => {
let done = q.defer(); let done = q.defer();
plugins.beautylog.info('npmts version: ' + npmtsProjectInfo.version);
const configArg: NpmtsConfig.INpmtsConfig = await NpmtsConfig.run(argvArg);
plugins.beautylog.ora.start('loading additional modules...'); plugins.beautylog.ora.start('loading additional modules...');
NpmtsMods.modCompile NpmtsMods.modCompile
.load() .load()
@ -93,13 +94,21 @@ export let run = async () => {
.then(NpmtsShip.run); .then(NpmtsShip.run);
return done.promise; return done.promise;
}) }, err => {
.catch(err => {
if (err instanceof Error) { if (err instanceof Error) {
console.log(err); console.log(err);
} }
}); })
// standard task
npmtsCli.standardTask().subscribe(async argvArg => {
await npmtsCli.trigger('build')
})
// cli metadata
npmtsCli.addVersion(npmtsProjectInfo.version); npmtsCli.addVersion(npmtsProjectInfo.version);
// start parsing
npmtsCli.startParse(); npmtsCli.startParse();
return await done.promise; return await done.promise;
}; };

View File

@ -32,7 +32,7 @@ export interface INpmtsConfig {
} }
export let run = function(argvArg) { export let run = function(argvArg) {
let done = smartq.defer(); let done = smartq.defer<INpmtsConfig>();
let defaultConfig: INpmtsConfig = { let defaultConfig: INpmtsConfig = {
argv: undefined, argv: undefined,
coverageTreshold: 70, coverageTreshold: 70,

View File

@ -6,7 +6,7 @@ import * as npmextra from 'npmextra';
import * as projectinfo from 'projectinfo'; import * as projectinfo from 'projectinfo';
import * as path from 'path'; import * as path from 'path';
import * as smartanalytics from 'smartanalytics'; import * as smartanalytics from 'smartanalytics';
import * as smartcli from 'smartcli'; import * as smartcli from '@pushrocks/smartcli';
import * as smarterror from 'smarterror'; import * as smarterror from 'smarterror';
import * as smartfile from 'smartfile'; import * as smartfile from 'smartfile';
import * as smartpath from 'smartpath'; import * as smartpath from 'smartpath';

990
yarn.lock

File diff suppressed because it is too large Load Diff