Skip to content

Instantly share code, notes, and snippets.

@fhemberger
Created November 20, 2015 23:14
Show Gist options
  • Select an option

  • Save fhemberger/3676b14899a4591498b3 to your computer and use it in GitHub Desktop.

Select an option

Save fhemberger/3676b14899a4591498b3 to your computer and use it in GitHub Desktop.

Revisions

  1. fhemberger renamed this gist Nov 20, 2015. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion gistfile1.txt → gistfile1.md
    Original file line number Diff line number Diff line change
    @@ -11,4 +11,6 @@ git rebase master
    git checkout master
    git merge --ff-only $branch
    git push origin master
    ```
    ```

    This closes the PR directly.
  2. fhemberger created this gist Nov 20, 2015.
    14 changes: 14 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    I'm using the [`git pr`](https://github.com/tj/git-extras/blob/master/Commands.md#git-pr) command from the [git-extras](https://github.com/tj/git-extras) toolset to check out a local copy of a PR.

    To rebase the PR again, I wrote a little script, which needs to be run in the PR's branch:

    ```bash
    #!/usr/bin/env bash

    branch=$(git symbolic-ref HEAD --short)

    git rebase master
    git checkout master
    git merge --ff-only $branch
    git push origin master
    ```