• Stars
    star
    2,609
  • Rank 17,549 (Top 0.4 %)
  • Language
    Ruby
  • License
    MIT License
  • Created about 15 years ago
  • Updated about 7 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

NOT MAINTAINED

git-up(1) -- fetch and rebase all locally-tracked remote branches

Code Climate

WARNING

This project is no longer maintained, for several reasons:

  • I've stopped using the workflow that made it relevant to me.
  • Git 2.0 updated the default behaviour to remove the main problem it was solving (by changing the default behaviour of git push so it acts only on the current branch, instead of all branches).
  • As of Git 2.9, git pull --rebase --autostash does basically the same thing.

Accordingly, if you update to Git 2.9 or later, you can use this alias instead of installing git-up:

git config --global alias.up 'pull --rebase --autostash'

If you'd rather this happened on every git pull, then you can do this:

git config --global pull.rebase true
git config --global rebase.autoStash true

SYNOPSIS

git pull has two problems:

  • It merges upstream changes by default, when it's really more polite to rebase over them, unless your collaborators enjoy a commit graph that looks like bedhead.
  • It only updates the branch you're currently on, which means git push will shout at you for being behind on branches you don't particularly care about right now.

Solve them once and for all.

INSTALL

$ gem install git-up

Windows support is predictably absent. Try the Python port, which was started for that reason.

USE

$ git up

ALTHOUGH

git-up is working well for a lot of people, but a rigorous proof has yet to be formulated that it will definitely not mess with your git setup, delete data or post inane drivel to Hacker News on your behalf. Best practice is to delete your Hacker News account before installing.

DIFFICULTIES

Windows

Windows support is an ongoing pain. Have a look at this ticket if you really need it, or if you're bored.

spawn.rb:187:in `_pspawn': Invalid command name (ArgumentError)

If you're using RVM and you get this error, read this.

CONFIGURATION

git-up has a few configuration options, which use git's configuration system. Each can be set either globally or per-project. To set an option globally, append the --global flag to git config, which you can run anywhere:

git config --global git-up.bundler.check true

To set it within a project, run the command inside that project's directory and omit the --global flag:

cd myproject
git config git-up.bundler.check true

git-up.bundler.check [true|false]

Default: false. If true, git-up will check your app for any new bundled gems and suggest a bundle install if necessary.

git-up.bundler.autoinstall [true|false]

Default: false. If true, and if git-up.bundler.check is also set to true, git-up will run bundle install for you if it finds missing gems.

git-up.fetch.prune [true|false]

Default: true. Append the --prune flag when running git fetch, if your git version supports it (1.6.6 or greater), telling it to remove any remote tracking branches which no longer exist on the remote.

git-up.fetch.all [true|false]

Default: false. Normally, git-up will only fetch remotes for which there is at least one local tracking branch. Setting this option to true will make git-up always fetch from all remotes, which is useful if e.g. you use a remote to push to your CI system but never check those branches out.

git-up.rebase.arguments [string]

Default: unset. Additional arguments to pass to git rebase. For example, setting this to --preserve-merges will recreate your merge commits in the rebased branch.

git-up.rebase.auto [true|false]

Default: true. If this option is set to false, git-up will not rebase branches for you. Instead, it will print a message saying they are diverged and let you handle rebasing them later. This can be useful if you have a lot of in-progress work that you don't want to deal with at once, but still want to update other branches.

git-up.rebase.log-hook "COMMAND"

Default: unset. Runs COMMAND every time a branch is rebased or fast-forwarded, with the old head as $1 and the new head as $2. This can be used to view logs or diffs of incoming changes. For example: 'echo "changes on $1:"; git log --oneline --decorate $1..$2'

More Repositories

1

deadweight

NOT MAINTAINED
Ruby
1,188
star
2

docker-wait

NOT MAINTAINED
Shell
154
star
3

jquery.tappable.js

NOT MAINTAINED
JavaScript
85
star
4

compose-file

Parser for the Compose file format (version 3)
Go
62
star
5

wick

NOT MAINTAINED
Ruby
33
star
6

do_notation

Haskell-style monad do-notation for Ruby
Ruby
25
star
7

gogol

A little sketch of a text-based time-rewinding game
CoffeeScript
17
star
8

cmon

HTML preprocessor for stable, cross-browser layouts
Ruby
16
star
9

itunes-web-interface

A web interface to iTunes
Ruby
14
star
10

feepogram

A tiny DSL for non-trivial bloopsaphone projects.
Ruby
10
star
11

docker-hubot

Dockerfile for building an IRC-enabled hubot
Shell
9
star
12

diversity-calculator

JavaScript
8
star
13

geocities-forever-html

HTML
8
star
14

anthrobot-twitterbot-example

Example Twitter bot using anthrobot. Source of https://twitter.com/_your_butt_
Python
7
star
15

tanktrum

A videogame.
Scala
6
star
16

datamosher

Python
6
star
17

shadowplay

JavaScript
6
star
18

jobdoer

JavaScript
4
star
19

do-notation.js

JavaScript
4
star
20

cdcovers

The source of cdcovers.heroku.com
Ruby
3
star
21

composit

Little HTML5 app that composites Flickr photos for any search term
JavaScript
3
star
22

geocities-forever

Python
3
star
23

re-readability

Arc90โ€™s Readability + John Holdunโ€™s Re-Reader = Aanand Prasadโ€™s Unnecessary Fussiness
Ruby
3
star
24

ive-seen-footage

Ruby
3
star
25

1901

A bloopsaphone cover of Phoenix's "1901"
Ruby
2
star
26

nnnnext

Source of nnnnext.com
JavaScript
2
star
27

wordpadbot

Python
2
star
28

compose-extends-demo

Python
2
star
29

anthrobot

Python
2
star
30

lrug-talk

1
star
31

aanand.github.com

HTML
1
star
32

fig-django-test

Python
1
star
33

howaboutnow

Python
1
star
34

NounNews

@NounNews Twitter Bot Source
Ruby
1
star
35

sass-align

nicely align property values in .sass files
Ruby
1
star
36

mandoline

Command-line tool to delete Cucumber features/scenarios by tag
Ruby
1
star
37

slitscanner

Python
1
star
38

transformers-talk

Ruby
1
star
39

vim-frank

The ignoble innocent.
Vim Script
1
star
40

docker-dnsutils

Docker image for Ubuntu's dnsutils package
Shell
1
star
41

scotruby-talk

Ruby
1
star
42

AirPiano

LeapMotion-controlled virtual piano. Not even nearly working yet.
C++
1
star