octopull
v2.0.0
Published
Your multi repo pull request buddy, octopull your git repos
Downloads
9
Readme
octopull
octopull /ˈɒktəpəs/ noun ~~a cephalopod mollusc with eight sucker-bearing arms, a soft sac-like body, strong beak-like jaws, and no internal shell.~~ Your multi repo pull request buddy :) octopull your git repos!
Why?
The microlibs and webcomponents era annd their multi repository nature, introduces a new complexity for chores and repository updating. After cloning, updating a travis files for 50 different repos, you'll get the point :P
octopull makes updating any set of files to any set of repositories a breeze.
Currently works only with GitHub
RDD - README driven development :P
Requirements
- NodeJS v6.0 or newer
- npm v3.10 or newer
Install
npm install octopull --save
Create .env file with token
Create a .env file in the root directory of your project.
GITHUB_TOKEN=your_token
Write simple script
const octopull = require('octopull')
const repos = [
{
owner: 'alvaropinot',
repo: 'test-redesigned-broccoli',
defaultBranch: 'master',
platform: 'github',
},
{
owner: 'alvaropinot',
repo: 'test-supreme-bassoon',
defaultBranch: 'master',
platform: 'github',
}
]
const options = {
files: ['foo.yml', 'bar.yml'],
branch: 'update-foo-and-bar', // autogenerated if blank
message: 'a cool commit msg', // autogenerated if blank
// OPTIONAL
pullRequest: {
title: 'a cool PR title', // autogenerated if blank
body: 'a cool PR body', // autogenerated if blank
// OPTIONAL
// assignees: ['username1', 'username2']
// reviewers: ['username3', 'username4']
}
}
repos.forEach((config) => octopull.commit(config, options))
Run the script
node yourScript.js
Example PR's created by octopull
- https://github.com/alvaropinot/test-redesigned-broccoli/pull/10
- https://github.com/alvaropinot/test-supreme-bassoon/pull/4
Develop
Setup
git clone https://github.com/alvaropinot/octopull
cd octopull
npm install
npm run dev
Run
cd examples
node githubPullRequest.js
License
MIT - @alvaropinot Alvaro Pinot
- CC Logo Octopus by Mark Aventura from the Noun Project
- CC Logo Octopus Tentacles by Iconic from the Noun Project