Histpush Extension

This extension is not distributed with Mercurial.

Author: Martin Blais

Download site: http://furius.ca/pubcode/pub/conf/lib/python/hgblais/histpush.py

Home page: http://furius.ca/pubcode/pub/conf/lib/python/hgblais/histpush.py.html

Works with: Mercurial 1.0 and beyond.

Overview

A Mercurial extension that allows you to locally track which revisions of a repository have been pushed to a remote repository.

When you use Mercurial in a completely disconnected fashion, at some point you may want to be able to find out if you have new revisions that need to be pushed out to a central repository, without having to connect it (this is the key: you can be off the network and it works). This command allows you to do that. It relies on an the installation of an 'outgoing' hook which stamps all revisions everytime you push. The record is kept under the '<root>/.hg/pushed.history' file

Configuration

Configure your .hgrc to enable the extension by adding following lines:

[extensions]
histpush = 

[hooks]
outgoing = python:histpush.update

Place histpush.py somewhere accessible from your PYTHONPATH.

Usage Scenario

To list the revisions that have never been pushed, just run the command:

   hg histpush

To force marking all the revisions in a repository as having been pushed, run with the --mark option:

   hg histpush --mark

You should do this once on an existing repository after installing the histpush extension, to initialize the history file.


CategoryExtensionsByOthers

HistpushExtension (last edited 2011-01-24 03:54:56 by SeanFlanigan)