About

Commit in all repositories with a command by Tiago Danin.


GitHub Push Global

Travis XO code style Node Version Downloads

Commit in all repositories with a command

Installation

Module available through the npm registry. It can be installed using the npm or yarn command line tools.

# NPM
npm install github-push-global --global
# Or Using Yarn
yarn global add github-push-global

Usage

# Show Help
github-push-global --help

# Basic
github-push-global \
	--file="code.js" \
	--to="code.js" \
	--github="tiagodanin" \
	--commit="Hello World" \
	--mode="replace" \
	--token="abcdf1234567890"

# Plugin
github-push-global \
	--plugin="examples/trust-packages.js" \
	--to="code.js" \
	--github="tiagodanin" \
	--commit="Hello World" \
	--mode="replace" \
	--token="abcdf1234567890"

Documentation

API Plugin

See examples in /examples

Structure

module.exports = ctx => {
	return false // Disable: git push
	return ctx.raw // String: file raw
	return ctx.data // Object: if is .JSON or is .YAML
}

ctx example

const ctx = {
	repo: {
		owner: 'Tiago Danin',
		name: 'GitHub-Push-Global'
	},
	data: {
		name: 'GitHub-Push-Global'
		// ... //
		// If file is JSON or YML, load data here
	},
	raw: '{"name": "GitHub-Push-Global"}',
	argv: {
		op: true
	} // Argv CLI
}

Tests

To run the test suite, first install the dependencies, then run test:

# NPM
npm test
# Or Using Yarn
yarn test

Dependencies

Dev Dependencies

Contributors

Pull requests and stars are always welcome. For bugs and feature requests, please create an issue. List of all contributors.

License

MIT © Tiago Danin


JavaScript

2