var GitHub = require('github-api');
// unauthenticated client
var gh = new GitHub({
username: 'foo',
password: 'bar'
});
var gist = gh.getGist(); // not a gist yet
var data = {
public: true,
description: 'My first gist',
files: {
"file1.txt": {
contents: "Aren't gists great!"
}
}
};
gist.create(data)
.then(function(httpResponse) {
var gistJson = httpResponse.data;
// Callbacks too
gist.read(function(err, gist, xhr) {
// if no error occurred then err == null
// gistJson == httpResponse.data
// xhr == httpResponse
});
});
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4