Differences between revisions 1 and 13 (spanning 12 versions)
Revision 1 as of 2007-01-18 03:32:04
Size: 2289
Editor: ppp-70-249-212-39
Comment:
Revision 13 as of 2007-02-13 18:49:48
Size: 4288
Editor: busch
Comment: Qct is now hosted on sourceforge
Deletions are marked like this. Additions are marked like this.
Line 6: Line 6:
Download site: [http://hg.borho.org/qct public development repository]. Download site:
 *
[http://qct.sourceforge.net/hg/qct public development repository].
 * [http://qct.sourceforge.net webpage]
Line 10: Line 12:
Qct is meant to be portable across platforms and version control tools, and requires Qt version 4.0 or later, which is not being distributed with Mercurial. Qct is meant to be portable across both platforms and version control tools, and requires Qt version 4.0 or later, which is not being distributed with Mercurial.
Line 12: Line 14:
The qct.py extension adds a {{{qct}}} command which supports only a single command line parameter. The qct.py extension adds a {{{qct}}} command, with alias {{{commit-tool}}}
Line 17: Line 19:
qct.py is located in the plugins directory. qct.py is located in the plugins directory of the source distribution. If, however, you've installed the windows self-extracting EXE file, you must download qct.py directly from the [http://qct.sourceforge.net/hg/qct/raw-file/tip/plugins/qct.py repository].
Line 19: Line 21:
To load an extension, you add it to your .hgrc file (you have to use your global $HOME/.hgrc file,
not one in a repository). You can specify an absolute path:
To load an extension, you add it to your .hgrc file (you have to use your global $HOME/.hgrc file, not one in a repository). You can specify an absolute path:
Line 34: Line 35:
If you are running on Windows, and qct.py is unable to find your Qct executable, you can specify the path to Qct in your .hgrc file: If you are running on Windows, and qct.py is unable to find your Qct executable, you can specify the path to Qct in your mercurial.ini file:
Line 38: Line 39:
path=/location/of/Qct.exe path="C:\Program Files\Qct\Qct.exe"
Line 41: Line 42:
Now hg help will show the new commands provided by the qct extension: You need to double-quote the path if it contains white spaces, as in the example above.

If you want to specify a sign-off message which is automatically appended to all of your commit messages, this can be enabled globally in the {{{qct}}} section in your ~/.hgrc file or locally in your repository's .hg/hgrc file:

{{{
[qct]
signoff = Signed-Off-By: Steve Borho
}}}

If your Mercurial repository has a policy requiring certain data to be included in every commit log, you can specify a template for this data in your repository root and Qct will use it to seed your log message at the start of each new commit.

{{{
echo "\nBug-ID:" > `hg root`/.commit.template
}}}

In Qct's preferences dialog, you can specify external tools that Qct can use to improve to provide more advanced features. For instance, if you provide Qct with the name of a two-way merge program, Qct will allow you to use this program to select individual changes made to files in your working directory (temporarily removing the remaining changes until after you commit, or when Qct exits).

Suggested two-way merge programs (on Unix/Linux) are Kompare, meld, and kdiff3.

If you have the ExtdiffExtension enabled, you can use it to spawn a GUI diff browser from within Qct. For example:

{{{
[extensions]
hgext.extdiff =

[extdiff]
cmd.vdiff = meld
}}}

You can now enter {{{hg vdiff}}} as the preferred diff browser in Qct preferences, and Qct will offer 'Visual Browser' in the context menus of modified files.

=== Usage ===
Now hg help will show the usage instructions for the qct extension:
Line 45: Line 78:
hg commit-tool [.] hg qct [options] [.]
Line 47: Line 80:
Qt-based GUI Commit Tool start qct commit tool
Line 67: Line 100:
aliases: qct aliases: commit-tool

options:

 -I --include include names matching the given patterns
 -X --exclude exclude names matching the given patterns
Line 73: Line 111:
Selected font size will be saved in ~/.gitk and reused in the next session. Window geometry, commit log history, and configuration data will be saved in ~/.config/vcs/qct.conf and reused in the next session.

Qct extension

This extension is not being distributed along with Mercurial.

Author: Steve Borho

Download site:

Overview

The qct.py extension provides improved access to the Qct graphical commit tool. Qct is meant to be portable across both platforms and version control tools, and requires Qt version 4.0 or later, which is not being distributed with Mercurial.

The qct.py extension adds a qct command, with alias commit-tool

Configuration

Follow Qct's INSTALL instructions to get the base application installed on your system.

qct.py is located in the plugins directory of the source distribution. If, however, you've installed the windows self-extracting EXE file, you must download qct.py directly from the [http://qct.sourceforge.net/hg/qct/raw-file/tip/plugins/qct.py repository].

To load an extension, you add it to your .hgrc file (you have to use your global $HOME/.hgrc file, not one in a repository). You can specify an absolute path:

[extensions]
qct=/usr/local/lib/qct.py

Mercurial can also scan the default python library path for a file named 'qct.py' if you set qct empty:

[extensions]
qct=

If you are running on Windows, and qct.py is unable to find your Qct executable, you can specify the path to Qct in your mercurial.ini file:

[qct]
path="C:\Program Files\Qct\Qct.exe"

You need to double-quote the path if it contains white spaces, as in the example above.

If you want to specify a sign-off message which is automatically appended to all of your commit messages, this can be enabled globally in the qct section in your ~/.hgrc file or locally in your repository's .hg/hgrc file:

[qct]
signoff = Signed-Off-By: Steve Borho

If your Mercurial repository has a policy requiring certain data to be included in every commit log, you can specify a template for this data in your repository root and Qct will use it to seed your log message at the start of each new commit.

echo "\nBug-ID:" > `hg root`/.commit.template

In Qct's preferences dialog, you can specify external tools that Qct can use to improve to provide more advanced features. For instance, if you provide Qct with the name of a two-way merge program, Qct will allow you to use this program to select individual changes made to files in your working directory (temporarily removing the remaining changes until after you commit, or when Qct exits).

Suggested two-way merge programs (on Unix/Linux) are Kompare, meld, and kdiff3.

If you have the ExtdiffExtension enabled, you can use it to spawn a GUI diff browser from within Qct. For example:

[extensions]
hgext.extdiff =

[extdiff]
cmd.vdiff = meld

You can now enter hg vdiff as the preferred diff browser in Qct preferences, and Qct will offer 'Visual Browser' in the context menus of modified files.

Usage

Now hg help will show the usage instructions for the qct extension:

$ hg help qct
hg qct [options] [.]

start qct commit tool

       If '.' is given as an argument the tool will operate out of the
       current directory, else it will operate repository-wide.

       This command will open a window from which you can browse all of
       the commitable changes you have made to your working directory.
       You can then enter a log message and commit your changes to the
       repository.  You can remove files from the commit list by
       de-selecting them in the file list.

       Keyboard Shortcuts:

       CTRL-O  - Commit selected files
       CTRL-R  - Refresh file list
       CTRL-N  - View diffs of next file in list
       CTRL-[] - Page up/down through file diffs
       CTRL-U  - Unselect all files
       ESC     - Abort and exit

aliases: commit-tool

options:

 -I --include  include names matching the given patterns
 -X --exclude  exclude names matching the given patterns

$ hg qct

Window geometry, commit log history, and configuration data will be saved in ~/.config/vcs/qct.conf and reused in the next session.


CategoryExtension

QctExtension (last edited 2011-04-02 20:16:55 by GregWard)