Skip to content

Commit b83a9f4

Browse files
committed
1.0.0
1 parent a688d4f commit b83a9f4

File tree

3 files changed

+9
-10
lines changed

3 files changed

+9
-10
lines changed

jshelp.js

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,15 @@ module.exports = {
2222

2323
return ready
2424
.then(function () {
25-
return npminfo(command.args[0])
25+
return new Promise(function (resolve, reject) {
26+
npm.commands.info([command.args[0], 'name', 'description'], true, function (err, res) {
27+
if (err) reject(err);
28+
else resolve(res);
29+
});
30+
});
2631
})
2732
.then(function (res) {
28-
const versions = res[0];
29-
const node_module = versions[Object.keys(versions)[0]];
33+
const node_module = res[Object.keys(res)[0]];
3034
return format('%s: %s - %s -> https://npmjs.org/package/%s',
3135
command.nickname, node_module.name, node_module.description, node_module.name);
3236
return (inspect(res));

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "tennu-jshelp",
3-
"version": "1.0.0rc2",
3+
"version": "1.0.0",
44
"description": "JS Help Plugin for Tennu IRC Bot Framework",
55
"main": "jshelp.js",
66
"scripts": {

readme.md

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,4 @@ None
1616

1717
## Hooks
1818

19-
None
20-
21-
## Bugs
22-
23-
The `npm` command will echo to stdout. If you know a solution to this,
24-
https://stackoverflow.com/questions/21070167/call-npm-infomodulename-without-printing-result-to-stdout
19+
None

0 commit comments

Comments
 (0)