Skip to content

Commit beaa082

Browse files
committed
Merge pull request #69 from matt-oc/master
sample data added to readme
2 parents 5180916 + e4c8a73 commit beaa082

File tree

4 files changed

+24
-3
lines changed

4 files changed

+24
-3
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
* toolbag removed.
44
* Checking that github url exists before trying to extract user and repo
55
* Stars, forks and watches are now assigned 0 instead of an empty string if repo.* is empty
6+
* Sample data added to Readme.
67

78
## 10 April - 6.2.0
89

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,25 @@ all available variable names.
8383
- Change the registry used to validate the module name.
8484
- Defaults to `http://registry.npmjs.org/`.
8585

86+
## Sample Data
87+
```json
88+
{
89+
"entity$": "-\/-\/github_cache",
90+
"name": "fuge",
91+
"user": "apparatus",
92+
"repo": "fuge",
93+
"stars": 155,
94+
"watches": 15,
95+
"forks": 18,
96+
"last": "2016-04-09T21:57:45Z",
97+
"urlRepo": "https:\/\/github.com\/apparatus\/fuge",
98+
"urlClone": "git+https:\/\/github.com\/apparatus\/fuge.git",
99+
"urlSsh": "git@github.com:apparatus\/fuge.git",
100+
"pullRequests": 1,
101+
"cached": 1461229347738
102+
}
103+
```
104+
86105
## Messages Handled
87106
This micro-service handles the following messages.
88107

lib/github.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,13 +59,13 @@ function cmdGet (msg, done) {
5959
}
6060

6161
if (!params.user || !params.repo) {
62-
return done(new Error('not found on npm'))
62+
return done(new Error('not found on github'))
6363
}
6464

6565
queryGithub(params, done)
6666
}
6767
else{
68-
return done(new Error('not found on npm'))
68+
return done(new Error('not found on github'))
6969
}
7070
})
7171
})

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"start": "node srv/start.js",
77
"isolated": "GITHUB_ISOLATED=true node srv/start.js",
88
"lint": "lab -P test -dL",
9-
"test": "lab -m 5000 -t 75 -v -P test",
9+
"test": "lab -v -P test -L -c -t 64",
1010
"cov": "lab -s -P test -r lcov | coveralls"
1111
},
1212
"main": "lib/github.js",
@@ -35,6 +35,7 @@
3535
"license": "MIT",
3636
"dependencies": {
3737
"github4": "0.5.4",
38+
"proxyquire": "1.7.4",
3839
"request": "2.70.0",
3940
"seneca": "2.0.0",
4041
"seneca-balance-client": "0.4.0",

0 commit comments

Comments
 (0)