Skip to content

Commit

Permalink
doc: document
Browse files Browse the repository at this point in the history
  • Loading branch information
joyeecheung committed Jan 17, 2018
1 parent 7042403 commit 6a255f0
Showing 1 changed file with 45 additions and 0 deletions.
45 changes: 45 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ CLI tools for Node.js Core collaborators.
- [Install](#install)
- [Setting up credentials](#setting-up-credentials)
- [`ncu-config`](#ncu-config)
- [`git-node-land`](#git-node-land)
- [Prerequistes](#prerequistes)
- [Usage](#usage-1)
- [`get-metadata`](#get-metadata)
- [Git bash for Windows](#git-bash-for-windows)
- [Features](#features)
Expand Down Expand Up @@ -85,6 +88,48 @@ Options:
--global [boolean] [default: false]
```

## `git-node-land`

A custom Git command for landing pull request. You can run it as
`git-node-land` or `git node land`.

### Prerequistes

1. It's a Git command, so make sure you have Git installed, of course.
2. Install [core-validate-commit](https://github.com/nodejs/core-validate-commit)

```
$ npm install -g core-validate-commit
```
3. Configure your upstream remote and branch name. By default it assumes your
remote pointing to https://github.com/nodejs/node is called `upstream`, and
the branch that you are trying to land PRs on is `master`. If that's not the
case:
```
$ cd path/to/node/project
$ ncu-config upstream your-remote-name
$ ncu-config branch your-branch-name
```
### Usage
Watch https://asciinema.org/a/148627 for a complete demo landing multiple
commits, or https://asciinema.org/a/157445 for a demo landing one commit.
```
$ cd path/to/node/project
$ git node land --abort # Abort a landing session, just in case
$ git node land $PRID # Start a new landing session

$ git rebase -i upstream/master # Put `edit` on every commit that's gonna stay

$ git node land --amend # Regenerate commit messages in HEAD
$ git rebase --continue # Repeat until the rebase is done

$ git node land --final # Verify all the commit messages
```
## `get-metadata`
This tool is inspired by Evan Lucas's [node-review](https://github.com/evanlucas/node-review),
Expand Down

0 comments on commit 6a255f0

Please sign in to comment.