lbry.tech/github.js

18 lines
361 B
JavaScript
Raw Normal View History

2018-05-11 22:08:44 +02:00
require('dotenv').config();
2018-05-11 10:36:07 +02:00
var octokit = require('@octokit/rest')();
2018-05-11 22:08:44 +02:00
var redis = require("redis"),
redisClient = redis.createClient(process.env.REDISCLOUD_URL);
2018-05-11 10:36:07 +02:00
octokit.activity.getEventsForOrg({
org: 'lbryio',
per_page: 20,
page: 1
}).then(function({data}) {
console.log(data);
2018-05-11 22:08:44 +02:00
redisClient.set('events', JSON.stringify(data), redis.print);
2018-05-11 10:36:07 +02:00
});