Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Commits on Oct 16, 2015
  1. @seanpdoyle

    Add `git pf` alias

    seanpdoyle committed
    Using `--force-with-lease` allows one to force push without the risk of
    unintentionally overwriting someone else's work.
    The git-push(1) man page states:
    > Usually, "git push" refuses to update a remote ref that is not an
    > ancestor of the local ref used to overwrite it.
    > This option overrides this restriction if the current value of the
    > remote ref is the expected value. "git push" fails otherwise.
    > --force-with-lease alone, without specifying the details, will protect
    > all remote refs that are going to be updated by requiring their
    > current value to be the same as the remote-tracking branch we have for
    > them.
    > --@calleerlandsson
    > -- thoughtbot/guides#363
Commits on Jul 12, 2015
  1. @blainesch
Commits on May 3, 2015
  1. @georgebrock

    Enable Git's autosquash feature by default.

    georgebrock committed
    Autosquash makes it quicker and easier to squash or fixup commits during an
    interactive rebase. It can be enabled for each rebase using `git rebase -i
    --autosquash`, but it's easier to turn it on by default.
    Say I have this history:
        $ git log --oneline
        aaa1111 A first commit
        bbb2222 A second commit
        ccc3333 A third commit
    I make another change that I already know should be squashed into "A
    second commit". I can do this:
        $ git add .
        $ git commit --squash bbb2222
        [my-branch ddd4444] squash! A second commit
    Then when I rebase:
        $ git rebase -i origin/my-branch
    The interactive rebase list will be set up ready to squash:
        pick aaa1111 A first commit
        pick bbb2222 A second commit
        squash ddd4444 squash! A second commit
        pick ccc3333 A third commit
    Since it's unlikely that anyone will be writing a commit message that begins
    `squash!` or `fixup!` when they don't want this behaviour, and the user
    still has a chance to review what's going to happen with the rebase, it's
    safe to have it always turned on.
Commits on Apr 27, 2015
  1. @croaky

    Move Git aliases to subcommand scripts

    croaky committed
    Any executable script on you PATH
    that is named `git-some-name`
    will be available as a git subcommand,
    which means you could do `git some-name` to run the script.
    Git adds them to `git help -a` under the title
    "git commands available from elsewhere on your $PATH",
    which will then power the auto completion,
    so that will also work for any command you add.
    Examples of other projects that structure their dotfiles like this:
Commits on Feb 23, 2015
  1. @blainesch

    Add the `-v` flag to `commit --amend`.

    blainesch committed
    This allows us to always see things we are going to commit, even if we
    are amending.
Commits on Feb 20, 2015
  1. @iwz

    Add `git branches` command

    iwz committed
    * Lists all remote branches
    * Sorts by last commit date, descending
    * Shows how long the branch has been around
    * Shows last commit author
    $ git branches
    6 days ago  Dan Croak  origin/HEAD
    6 days ago  Dan Croak  origin/master
    5 months ago  Dan Croak  origin/dc-rbenv-zsh
    6 months ago  Sean Doyle  origin/sd-nvm-path
    6 months ago  Tute Costa  origin/vim-multiple-cursors
    7 months ago  Sean Doyle  origin/sd-vundle
    8 months ago  Sean Griffin  origin/sg-disable-spring
    9 months ago  Mike Burns  origin/mb-experimental-tag
Commits on Feb 18, 2015
  1. @croaky

    Switch from gh to hub

    croaky committed
    * `hub` is the official GitHub client.
    * Like `gh`, `hub` 2.2.0 now powered by the Go programming language.
    * It has been bottled in Homebrew.
    * We are using it in the Laptop script.
Commits on Jan 26, 2015
  1. @croaky

    Add `git rename-branch` alias

    croaky committed
    * Extract `git current-branch` alias.
    * Re-use `git current-branch` in two places.
Commits on Nov 2, 2014
  1. Revert "include, filter, user"

    Ian Zabel committed
    This reverts commit 383612a.
  2. @iwz

    include, filter, user

    iwz committed
Commits on Oct 19, 2014
  1. @jkrmr

    Include local gitconfig at the end of .gitconfig

    jkrmr committed
    Allows for customizing git's commit message template and overriding fetch.prune.
Commits on Sep 30, 2014
  1. @croaky

    Use `gh`, not `hub`

    croaky committed
    [gh] is a [hub] reimplementation that's much faster and is now the official
    Github CLI. It appears that "hub" is [deprecated].
    [deprecated]: github/hub#475
    Matches thoughtbot/laptop:
Commits on Aug 27, 2014
  1. @seanpdoyle

    Introduces `git_template` for init templating

    seanpdoyle committed
    Inspired by
    * Make `ctags` executable configurable
    * Adds `git ctags`
    * Runs `ctag` on `commit` / `branch` / `checkout`
    * Extensible via `~/.git_template.local/hooks/{pre,post}-*`
    * explain `git_template` under `git` section
Commits on Jul 26, 2014
  1. @croaky

    Make it easy to checkout GitHub pull requests

    croaky committed
    This alias makes the following workflow possible:
    Look at changes:
        git co-pr 123
        git diff origin/master
    Bundle, validate tests are passing:
    Rebase interactively, squash, and potentially improve commit messages:
        git rebase -i master
    Merge code into master:
        git checkout master
        git merge pr/123 --ff-only
        git push origin master
    Clean up:
        git branch -D pr/123
Commits on Apr 21, 2014
  1. @jferris

    Automatically prune remote branches when fetching

    jferris committed
    * Removes the need to occasionally run `git remote prune`.
    * Remove branches when fetching instead of deleting other branches.
Commits on Oct 8, 2013
  1. @mike-burns

    Add a commit message template

    mike-burns committed
    Using the `commit.template` setting, read in a commit message template
    for each commit. This template is commented out so the commit message
    author doesn't need to delete it.
    The template serves as a reminder on how to write a better commit
    message. The bullets are taken from Caleb's blog post[1]. There is no
    _problem_ per se -- we are writing good messages these days -- but it's
    handy to be reminded of things to think about. For example, people often
    forget to note whether there are any side effects.
    This message does not show on `git commit --amend`, only normal `git
Commits on Jul 11, 2013
  1. @croaky

    Git push to current, not upstream

    croaky committed
    The primary use case for me is to `git push staging` and `git push
    production` from the master branch using our typical git workflow:
Commits on Jun 28, 2013
  1. @gylaz

    Include gitconfig.local file for personal changes

    gylaz committed
    * assumes same directory existance
    * allows for easier addition of personal configs
Commits on Jun 11, 2013
  1. @croaky
Commits on Apr 19, 2013
  1. @croaky
Commits on Apr 14, 2013
  1. @croaky

    Remove `git br` alias

    croaky committed
    I almost never use `git branch`.
Commits on Apr 10, 2013
  1. @croaky

    Always merge with `ff = only`

    croaky committed
    This has the effect that Git will never implicitly do a merge commit,
    including while doing git pull. If I'm unexpectedly out of sync when I
    git pull, I get this message:
    > fatal: Not possible to fast-forward, aborting.
    At that point, I know that I've forgotten to do something in my normal
    workflow, and I retrace my steps.
    I like the value of seeing a failure message if a pull (or just merge)
    fails due to not being able to get fast-forwarded. Then I can look to
    see whose changes went out, that I may have not expected to be there.
Commits on Apr 9, 2013
  1. @gylaz
Commits on Mar 9, 2013
  1. @derekprior @croaky
Commits on Feb 24, 2013
  1. @joshuaclayton @croaky

    Update git's push.default from tracking to upstream

    joshuaclayton committed with croaky
    The 'tracking' value has been deprecated in favor of 'upstream'.
Commits on Feb 21, 2013
  1. @jferris

    Revert to default Git log style

    jferris committed
    * Our current style hides message details
    * Default style shows details and one-line versions as appropriate
Commits on Feb 13, 2013
  1. @gylaz

    Add git alias branch as br

    gylaz committed
Commits on Jan 18, 2013
  1. @croaky
Commits on Oct 9, 2012
  1. @croaky

    Add basic git aliases

    croaky committed with Dan Croak
    * Fast commits.
    * Fast rebase of origin into feature branch.
    * Fast merge feature branch into master.
    * Fast branch creation.
    * Fast branch deletion.
Commits on Oct 24, 2011
  1. @croaky

    adding a global .gitconfig that by default tracks branches (so you ca…

    croaky committed
    …n 'git push' from a branch it only pushes to the tracking branch you're in) and also provides a tighter, more colorful git log
Something went wrong with that request. Please try again.