Created
September 9, 2018 03:32
-
-
Save seiyria/6e4ba9491834dee98a3d0cb08d5bbfdc to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const octokit = require('@octokit/rest')(); | |
const snake = require('lodash.snakecase'); | |
const fs = require('fs'); | |
octokit.search.issues({ | |
q: 'repo:landoftherair/landoftherair is:open' | |
}) | |
.then(res => { | |
res.data.items.forEach(item => { | |
fs.writeFileSync(`issue-${item.number} (${snake(item.title)}).md`, item.body); | |
}); | |
}) | |
.catch(e => { | |
console.error(e); | |
});; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment