add beautycolor
This commit is contained in:
parent
cbc47db2ed
commit
ea5f1af440
4
dist/smartnpm.classes.npmregistry.js
vendored
4
dist/smartnpm.classes.npmregistry.js
vendored
@ -77,7 +77,7 @@ class NpmRegistry {
|
||||
if (searchObjectArg.maintenanceWeight) {
|
||||
addToSearchString(`author:${searchObjectArg.maintenanceWeight}`);
|
||||
}
|
||||
plugins.beautylog.log(`Search for "${searchString}" on npm`);
|
||||
plugins.beautylog.log(`Search on npm for ${plugins.beautycolor.coloredString(searchString, 'pink')}`);
|
||||
let response = (yield plugins.smartrequest.get(this.searchDomain + searchString, {}));
|
||||
let body = response.body;
|
||||
// lets create the response
|
||||
@ -91,4 +91,4 @@ class NpmRegistry {
|
||||
}
|
||||
}
|
||||
exports.NpmRegistry = NpmRegistry;
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic21hcnRucG0uY2xhc3Nlcy5ucG1yZWdpc3RyeS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL3NtYXJ0bnBtLmNsYXNzZXMubnBtcmVnaXN0cnkudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7OztBQUFBLDhDQUE2QztBQUs3QyxVQUFVO0FBQ1YsK0VBQTBEO0FBRTFEO0lBQUE7UUFDVSxpQkFBWSxHQUFHLGtDQUFrQyxDQUFBO0lBOEQzRCxDQUFDO0lBN0RPLE1BQU0sQ0FBRSxlQUE4Qjs7WUFDMUMsSUFBSSxZQUFZLEdBQUcsRUFBRSxDQUFBO1lBQ3JCLElBQUksaUJBQWlCLEdBQUcsQ0FBQyxZQUFvQjtnQkFDM0MsWUFBWSxHQUFHLEdBQUcsWUFBWSxJQUFJLFlBQVksRUFBRSxDQUFBO1lBQ2xELENBQUMsQ0FBQTtZQUVELE9BQU87WUFDUCxFQUFFLENBQUMsQ0FBQyxlQUFlLENBQUMsSUFBSSxDQUFDLENBQUMsQ0FB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NyRixJQUFJLElBQUksR0FBUSxRQUFRLENBQUMsSUFBSSxDQUFBO1lBRTdCLDJCQUEyQjtZQUMzQixJQUFJLFlBQVksR0FBaUIsRUFBRSxDQUFBO1lBRW5DLEdBQUcsQ0FBQyxDQUFDLElBQUksVUFBVSxJQUFJLElBQUksQ0FBQyxPQUFPLENBQUMsQ0FBQyxDQUFDO2dCQUNwQyxJQUFJLFlBQVksR0FBRyxJQUFJLHdDQUFVLENBQUMsVUFBVSxDQUFDLE9BQU8sQ0FBQyxDQUFBO2dCQUNyRCxZQUFZLENBQUMsSUFBSSxDQUFDLFlBQVksQ0FBQyxDQUFBO1lBQ2pDLENBQUM7WUFFRCxNQUFNLENBQUMsWUFBWSxDQUFBO1FBQ3JCLENBQUM7S0FBQTtDQUNGO0FBL0RELGtDQStEQyJ9
|
3
dist/smartnpm.plugins.d.ts
vendored
3
dist/smartnpm.plugins.d.ts
vendored
@ -1,4 +1,5 @@
|
||||
import 'typings-global';
|
||||
import * as beautycolor from 'beautycolor';
|
||||
import * as beautylog from 'beautylog';
|
||||
import * as smartrequest from 'smartrequest';
|
||||
export { beautylog, smartrequest };
|
||||
export { beautycolor, beautylog, smartrequest };
|
||||
|
4
dist/smartnpm.plugins.js
vendored
4
dist/smartnpm.plugins.js
vendored
@ -1,8 +1,10 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
require("typings-global");
|
||||
const beautycolor = require("beautycolor");
|
||||
exports.beautycolor = beautycolor;
|
||||
const beautylog = require("beautylog");
|
||||
exports.beautylog = beautylog;
|
||||
const smartrequest = require("smartrequest");
|
||||
exports.smartrequest = smartrequest;
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic21hcnRucG0ucGx1Z2lucy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL3NtYXJ0bnBtLnBsdWdpbnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSwwQkFBdUI7QUFFdkIsdUNBQXNDO0FBSXBDLDhCQUFTO0FBSFgsNkNBQTRDO0FBSTFDLG9DQUFZIn0=
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic21hcnRucG0ucGx1Z2lucy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL3NtYXJ0bnBtLnBsdWdpbnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSwwQkFBdUI7QUFFdkIsMkNBQTBDO0FBS3hDLGtDQUFXO0FBSmIsdUNBQXNDO0FBS3BDLDhCQUFTO0FBSlgsNkNBQTRDO0FBSzFDLG9DQUFZIn0=
|
@ -13,6 +13,7 @@
|
||||
"tapbundle": "^1.0.13"
|
||||
},
|
||||
"dependencies": {
|
||||
"beautycolor": "^1.0.9",
|
||||
"beautylog": "^6.1.10",
|
||||
"smartrequest": "^1.0.6",
|
||||
"typings-global": "^1.0.16"
|
||||
|
@ -54,7 +54,7 @@ export class NpmRegistry {
|
||||
if (searchObjectArg.popularityWeight) { addToSearchString(`author:${searchObjectArg.popularityWeight}`) }
|
||||
if (searchObjectArg.maintenanceWeight) { addToSearchString(`author:${searchObjectArg.maintenanceWeight}`) }
|
||||
|
||||
plugins.beautylog.log(`Search for "${searchString}" on npm`)
|
||||
plugins.beautylog.log(`Search on npm for ${plugins.beautycolor.coloredString(searchString, 'pink')}`)
|
||||
|
||||
let response = (await plugins.smartrequest.get(this.searchDomain + searchString, {}))
|
||||
let body: any = response.body
|
||||
|
@ -1,9 +1,11 @@
|
||||
import 'typings-global'
|
||||
|
||||
import * as beautycolor from 'beautycolor'
|
||||
import * as beautylog from 'beautylog'
|
||||
import * as smartrequest from 'smartrequest'
|
||||
|
||||
export {
|
||||
beautycolor,
|
||||
beautylog,
|
||||
smartrequest
|
||||
}
|
||||
|
10
yarn.lock
10
yarn.lock
@ -84,6 +84,14 @@ beautycolor@^1.0.7:
|
||||
ansi-256-colors "^1.1.0"
|
||||
typings-global "^1.0.14"
|
||||
|
||||
beautycolor@^1.0.9:
|
||||
version "1.0.9"
|
||||
resolved "https://registry.yarnpkg.com/beautycolor/-/beautycolor-1.0.9.tgz#639eaa83b6b9ca8419f164e42df33e162f839a3b"
|
||||
dependencies:
|
||||
ansi-256-colors "^1.1.0"
|
||||
tapbundle "^1.1.1"
|
||||
typings-global "^1.0.14"
|
||||
|
||||
beautylog@^6.1.10:
|
||||
version "6.1.10"
|
||||
resolved "https://registry.yarnpkg.com/beautylog/-/beautylog-6.1.10.tgz#9c27e566937684cb689f9372d98cfa5415d50b72"
|
||||
@ -466,7 +474,7 @@ supports-color@^2.0.0:
|
||||
version "2.0.0"
|
||||
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7"
|
||||
|
||||
tapbundle@^1.0.13:
|
||||
tapbundle@^1.0.13, tapbundle@^1.1.1:
|
||||
version "1.1.1"
|
||||
resolved "https://registry.yarnpkg.com/tapbundle/-/tapbundle-1.1.1.tgz#ec4172c0e82a77b1f6133fef2606311ede28a62d"
|
||||
dependencies:
|
||||
|
Loading…
Reference in New Issue
Block a user