refactor github and inquirer calls in init.js