Skip to content
This repository was archived by the owner on Aug 31, 2024. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 16 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
Exposes `gh` to the global environment. Tries to follow both the form of Github
HTTP API and JS style.

gh.authenticate("fitzgen", "sdfk32we-FAKE-uydfs7f-rhrwe8r7");
var huddlej = gh.user("huddlej");
huddlej.show(function (data) {
console.log(data.user);
});
huddlej.repos(function (data) {
console.log("Number of repos: " + data.repositories.length);
});
var wujs = gh.repo("fitzgen", "wu.js")
wujs.show(function (data) {
console.log("Number of watchers: " + data.repository.watchers);
});
wujs.update({ has_wiki: 0 }); // Unfortunately, no callbacks with POSTs :(
```js
gh.authenticate("fitzgen", "sdfk32we-FAKE-uydfs7f-rhrwe8r7");
var huddlej = gh.user("huddlej");
huddlej.show(function (data) {
console.log(data.user);
});
huddlej.repos(function (data) {
console.log("Number of repos: " + data.repositories.length);
});
var wujs = gh.repo("fitzgen", "wu.js")
wujs.show(function (data) {
console.log("Number of watchers: " + data.repository.watchers);
});
wujs.update({ has_wiki: 0 }); // Unfortunately, no callbacks with POSTs :(
```

COMPLETE
========
Expand All @@ -30,4 +32,4 @@ COMPLETE
TODO
====

* Documentation
* Documentation