Differences between revisions 72 and 124 (spanning 52 versions)
Revision 72 as of 2007-04-06 12:47:45
Size: 13270
Editor: 59
Comment: None
Revision 124 as of 2008-05-29 06:10:27
Size: 6623
Comment: Added `hg status -an0 | xargs -r0 hg revert` trick to revert just pending adds
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
Hello, very nice site! Please also visit my homepages:
 [URL=http://www.greatprise.org/insurance/index.html]insurance[/URL] [URL=http://www.greatprise.org/insurance-life-settlement/index.html]insurance life settlement[/URL] [URL=http://www.greatprise.org/health-insurance/index.html]health insurance[/URL] [URL=http://www.greatprise.org/care-insurance-long-term/index.html]care insurance long term[/URL] [URL=http://www.greatprise.org/boat-insurance/index.html]boat insurance[/URL] [URL=http://www.greatprise.org/car-cheapest-insurance/index.html]car cheapest insurance[/URL] [URL=http://www.greatprise.org/auto-insurance-progressive/index.html]auto insurance progressive[/URL] [URL=http://www.greatprise.org/florida-health-insurance/index.html]florida health insurance[/URL] [URL=http://www.greatprise.org/insurance-mercury/index.html]insurance mercury[/URL] [URL=http://www.greatprise.org/car-cheap-insurance/index.html]car cheap insurance[/URL] [URL=http://www.greatprise.org/home-insurance-quote/index.html]home insurance quote[/URL] [URL=http://www.greatprise.org/insurance-rv/index.html]insurance rv[/URL] [URL=http://www.greatprise.org/farm-insurance-state/index.html]farm insurance state[/URL] [URL=http://www.greatprise.org/insurance-online-quote/index.html]insurance online quote[/URL] [URL=http://www.greatprise.org/insurance-medical-travel/index.html]insurance medical travel[/URL] [URL=http://www.greatprise.org/automotive-de-insurance-wilmington/index.html]automotive de insurance wilmington[/URL] [URL=http://www.greatprise.org/aetna-health-insurance/index.html]aetna health insurance[/URL] [URL=http://www.greatprise.org/california-car-insurance/index.html]california car insurance[/URL] [URL=http://www.greatprise.org/auto-insurance-rate/index.html]auto insurance rate[/URL] [URL=http://www.greatprise.org/aaa-insurance/index.html]aaa insurance[/URL] [URL=http://www.greatprise.org/insurance-life-quote-term/index.html]insurance life quote term[/URL] [URL=http://www.greatprise.org/adjuster-insurance/index.html]adjuster insurance[/URL] [URL=http://www.greatprise.org/health-insurance-texas/index.html]health insurance texas[/URL] [URL=http://www.greatprise.org/employment-insurance/index.html]employment insurance[/URL] [URL=http://www.greatprise.org/claim-insurance/index.html]claim insurance[/URL] [URL=http://www.greatprise.org/disability-insurance/index.html]disability insurance[/URL] [URL=http://www.greatprise.org/agent-broker-carrier-insurance/index.html]agent broker carrier insurance[/URL] [URL=http://www.greatprise.org/insurance-life/index.html]insurance life[/URL] [URL=http://www.greatprise.org/insurance-quote/index.html]insurance quote[/URL] [URL=http://www.greatprise.org/car-insurance-new-york/index.html]car insurance new york[/URL] [URL=http://www.greatprise.org/attorney-insurance/index.html]attorney insurance[/URL] [URL=http://www.greatprise.org/allstate-insurance/index.html]allstate insurance[/URL] [URL=http://www.greatprise.org/insurance-nationwide/index.html]insurance nationwide[/URL] [URL=http://www.greatprise.org/cost-health-insurance-low/index.html]cost health insurance low[/URL] [URL=http://www.greatprise.org/health-insurance-international-travel/index.html]health insurance international travel[/URL] [URL=http://www.greatprise.org/company-insurance-life/index.html]company insurance life[/URL] [URL=http://www.greatprise.org/car-cost-insurance-low/index.html]car cost insurance low[/URL] [URL=http://www.greatprise.org/dental-insurance/index.html]dental insurance[/URL] [URL=http://www.greatprise.org/car-insurance-online/index.html]car insurance online[/URL] [URL=http://www.greatprise.org/auto-insurance-online/index.html]auto insurance online[/URL] [URL=http://www.greatprise.org/insurance-renters/index.html]insurance renters[/URL] [URL=http://www.greatprise.org/insurance-mortgage/index.html]insurance mortgage[/URL] [URL=http://www.greatprise.org/california-health-insurance/index.html]california health insurance[/URL] [URL=http://www.greatprise.org/business-insurance/index.html]business insurance[/URL] [URL=http://www.greatprise.org/car-insurance-online-quote/index.html]car insurance online quote[/URL] [URL=http://www.greatprise.org/auto-california-insurance/index.html]auto california insurance[/URL] [URL=http://www.greatprise.org/home-insurance-owner/index.html]home insurance owner[/URL] [URL=http://www.greatprise.org/group-health-insurance/index.html]group health insurance[/URL] [URL=http://www.greatprise.org/insurance-traveler/index.html]insurance traveler[/URL] [URL=http://www.greatprise.org/affordable-health-insurance/index.html]affordable health insurance[/URL] [URL=http://www.greatprise.org/insurance-life-term/index.html]insurance life term[/URL] [URL=http://www.greatprise.org/insurance-international-medical-travel/index.html]insurance international medical travel[/URL] [URL=http://www.greatprise.org/company-insurance/index.html]company insurance[/URL] [URL=http://www.greatprise.org/accident-insurance-travel/index.html]accident insurance travel[/URL] [URL=http://www.greatprise.org/insurance-travel/index.html]insurance travel[/URL] [URL=http://www.greatprise.org/insurance-online-travel/index.html]insurance online travel[/URL] [URL=http://www.greatprise.org/insurance-term/index.html]insurance term[/URL] [URL=http://www.greatprise.org/health-insurance-quote/index.html]health insurance quote[/URL] [URL=http://www.greatprise.org/hartford-insurance/index.html]hartford insurance[/URL] [URL=http://www.greatprise.org/insurance-lead/index.html]insurance lead[/URL] [URL=http://www.greatprise.org/health-insurance-plan/index.html]health insurance plan[/URL] [URL=http://www.greatprise.org/car-free-insurance-quote/index.html]car free insurance quote[/URL] [URL=http://www.greatprise.org/health-insurance-short-term/index.html]health insurance short term[/URL] [URL=http://www.greatprise.org/insurance-usaa/index.html]insurance usaa[/URL] [URL=http://www.greatprise.org/insurance-pet/index.html]insurance pet[/URL] [URL=http://www.greatprise.org/car-insurance-quote/index.html]car insurance quote[/URL] [URL=http://www.greatprise.org/insurance-life-whole/index.html]insurance life whole[/URL] [URL=http://www.greatprise.org/car-insurance-rate/index.html]car insurance rate[/URL] [URL=http://www.greatprise.org/home-insurance-owner-quote/index.html]home insurance owner quote[/URL] [URL=http://www.greatprise.org/geico-insurance/index.html]geico insurance[/URL] [URL=http://www.greatprise.org/automobile-insurance-quote/index.html]automobile insurance quote[/URL]
 <a href="http://www.greatprise.org/insurance-international-medical-travel/index.html">insurance international medical travel</a> <a href="http://www.greatprise.org/company-insurance/index.html">company insurance</a> <a href="http://www.greatprise.org/insurance-nationwide/index.html">insurance nationwide</a> <a href="http://www.greatprise.org/car-cheapest-insurance/index.html">car cheapest insurance</a> <a href="http://www.greatprise.org/family-health-insurance/index.html">family health insurance</a> <a href="http://www.greatprise.org/home-insurance/index.html">home insurance</a> <a href="http://www.greatprise.org/home-insurance-owner/index.html">home insurance owner</a> <a href="http://www.greatprise.org/agent-insurance/index.html">agent insurance</a> <a href="http://www.greatprise.org/insurance-medical/index.html">insurance medical</a> <a href="http://www.greatprise.org/disability-insurance/index.html">disability insurance</a> <a href="http://www.greatprise.org/broker-insurance/index.html">broker insurance</a> <a href="http://www.greatprise.org/claim-insurance/index.html">claim insurance</a> <a href="http://www.greatprise.org/car-cost-insurance-low/index.html">car cost insurance low</a> <a href="http://www.greatprise.org/health-individual-insurance/index.html">health individual insurance</a> <a href="http://www.greatprise.org/insurance-term/index.html">insurance term</a> <a href="http://www.greatprise.org/allstate-insurance/index.html">allstate insurance</a> <a href="http://www.greatprise.org/business-health-insurance-small/index.html">business health insurance small</a> <a href="http://www.greatprise.org/auto-insurance-progressive/index.html">auto insurance progressive</a> <a href="http://www.greatprise.org/california-car-insurance/index.html">california car insurance</a> <a href="http://www.greatprise.org/farmer-insurance/index.html">farmer insurance</a> <a href="http://www.greatprise.org/home-insurance-owner-quote/index.html">home insurance owner quote</a> <a href="http://www.greatprise.org/hartford-insurance/index.html">hartford insurance</a> <a href="http://www.greatprise.org/ca-health-insurance/index.html">ca health insurance</a> <a href="http://www.greatprise.org/affordable-health-insurance/index.html">affordable health insurance</a> <a href="http://www.greatprise.org/insurance/index.html">insurance</a> <a href="http://www.greatprise.org/aetna-health-insurance/index.html">aetna health insurance</a> <a href="http://www.greatprise.org/accident-insurance-travel/index.html">accident insurance travel</a> <a href="http://www.greatprise.org/insurance-motorcycle/index.html">insurance motorcycle</a> <a href="http://www.greatprise.org/geico-insurance/index.html">geico insurance</a> <a href="http://www.greatprise.org/car-insurance/index.html">car insurance</a> <a href="http://www.greatprise.org/free-insurance-quote/index.html">free insurance quote</a> <a href="http://www.greatprise.org/business-insurance/index.html">business insurance</a> <a href="http://www.greatprise.org/home-insurance-quote/index.html">home insurance quote</a> <a href="http://www.greatprise.org/insurance-mortgage/index.html">insurance mortgage</a> <a href="http://www.greatprise.org/car-insurance-quote/index.html">car insurance quote</a> <a href="http://www.greatprise.org/automobile-insurance-quote/index.html">automobile insurance quote</a> <a href="http://www.greatprise.org/automotive-de-insurance-wilmington/index.html">automotive de insurance wilmington</a> <a href="http://www.greatprise.org/insurance-pet/index.html">insurance pet</a> <a href="http://www.greatprise.org/car-free-insurance-quote/index.html">car free insurance quote</a> <a href="http://www.greatprise.org/insurance-online-quote/index.html">insurance online quote</a> <a href="http://www.greatprise.org/insurance-medical-travel/index.html">insurance medical travel</a> <a href="http://www.greatprise.org/health-insurance-international-travel/index.html">health insurance international travel</a> <a href="http://www.greatprise.org/insurance-quote/index.html">insurance quote</a> <a href="http://www.greatprise.org/agent-broker-carrier-insurance/index.html">agent broker carrier insurance</a> <a href="http://www.greatprise.org/health-insurance-plan/index.html">health insurance plan</a> <a href="http://www.greatprise.org/insurance-usaa/index.html">insurance usaa</a> <a href="http://www.greatprise.org/auto-insurance-online/index.html">auto insurance online</a> <a href="http://www.greatprise.org/insurance-life-settlement/index.html">insurance life settlement</a> <a href="http://www.greatprise.org/insurance-life-policy/index.html">insurance life policy</a> <a href="http://www.greatprise.org/auto-california-insurance/index.html">auto california insurance</a> <a href="http://www.greatprise.org/insurance-renters/index.html">insurance renters</a> <a href="http://www.greatprise.org/insurance-travel/index.html">insurance travel</a> <a href="http://www.greatprise.org/auto-geico-insurance/index.html">auto geico insurance</a> <a href="http://www.greatprise.org/insurance-mercury/index.html">insurance mercury</a> <a href="http://www.greatprise.org/farm-insurance-state/index.html">farm insurance state</a>
 http://www.greatprise.org/geico-insurance/index.html http://www.greatprise.org/insurance-international-medical-travel/index.html http://www.greatprise.org/insurance-unemployment/index.html http://www.greatprise.org/attorney-insurance/index.html http://www.greatprise.org/insurance-life/index.html http://www.greatprise.org/employment-insurance/index.html http://www.greatprise.org/affordable-health-insurance/index.html http://www.greatprise.org/insurance-life-quote/index.html http://www.greatprise.org/florida-health-insurance/index.html http://www.greatprise.org/insurance-usaa/index.html http://www.greatprise.org/car-insurance-rate/index.html http://www.greatprise.org/automobile-insurance-quote/index.html http://www.greatprise.org/insurance-nationwide/index.html http://www.greatprise.org/health-insurance-quote/index.html http://www.greatprise.org/auto-geico-insurance/index.html http://www.greatprise.org/american-family-insurance/index.html http://www.greatprise.org/boston-insurance/index.html http://www.greatprise.org/dental-insurance/index.html http://www.greatprise.org/home-insurance-owner-quote/index.html http://www.greatprise.org/health-insurance-international-travel/index.html http://www.greatprise.org/insurance-marketing/index.html http://www.greatprise.org/car-insurance-online-quote/index.html
Thanks!
----
CategoryExtension
#pragma section-numbers 3
= Tips and Tricks =
''(see also [:FAQ], [:HOWTOs], [wiki:Self:CategoryTipsAndTricks CategoryTipsAndTricks])''

|| [[TableOfContents]] || [[Include(/Index)]] ||

=== Undo an "hg add" ===
{{{
hg revert # take out of source control
hg rm -f # remove it
}}}

On Unix, to revert just the pending adds, you can use
{{{
hg status -an0 | xargs -r0 hg revert
}}}

=== Save a push URL so that you don't need to enter it each time ===
It is possible to store a default [:Push:push] URL that will be used when you type just "hg push". Edit [:.hgrc:hgrc] and add something like:

{{{
[paths]
default-push = ssh://hg@example.com/path
}}}

=== Track changes to a repository with RSS ===
You can track changes to projects and individual files with RSS feeds from hgweb. Here are some examples:

 * http://selenic.com/hg/rss-log/
 * http://selenic.com/hg/rss-log/tip/mercurial/hgweb/hgweb_mod.py

=== Create links to snapshots of files and tarballs ===
If you want to create web links to [:Tag:tagged] or [:Tip:tip] versions of a [:Repository:repository] or a file, you can do so like this:

 * http://selenic.com/hg/archive/tip.tar.gz
 * http://selenic.com/hg/archive/0.9.3.zip
 * http://selenic.com/hg/raw-file/tip/COPYING
 * http://selenic.com/hg/raw-file/0.9.3/COPYING

=== Configuring Mercurial ===
See in [:.hgrc].

=== Abbreviate command options ===
It is possible to abbreviate command options:
{{{
hg revert --no-b
hg revert --no-backup
}}}

=== Ignore files from Emacs/XEmacs ===
Add the following to [:.hgignore]:

{{{
syntax: glob
*~

syntax: regexp
(.*/)?\#[^/]*\#$
}}}

=== Make a clean copy of a source tree, like CVS export ===
{{{
hg clone source export
rm -rf export/.hg
}}}
or using the archive command
{{{
cd source
hg archive ../export
}}}

The same thing, but for a [:Tag:tagged] release:

{{{
hg clone --noupdate source export-tagged
cd export-tagged
hg update mytag
rm -rf .hg
}}}
or using the archive command
{{{
cd source
hg archive -r mytag ../export-tagged
}}}

=== One liner to remove unknown files with a pattern ===
To make these work, replace the {{{ls -l}}} with the command you wish to execute (ie. {{{rm}}}). You can also tweak the parameters passed to {{{hg status}}} to filter by something other than unknown files (see {{{hg help status}}}).

{{{
hg status -nu0 | grep -z pattern | xargs -0r ls -l
}}}

The above command requires a current version of GNU grep. If you don't have one, you can use the following:
{{{
hg status -nu | grep pattern | tr '\n' '\0' | xargs -0r ls -l
}}}

=== Generating color diff output with extdiff and colordiff ===
You can use the [:ExtdiffExtension:extdiff extension] to get colorized diff output. If you've enabled the extension and have colordiff installed, the following [:.hgrc:hgrc] snippet will create a new {{{cdiff}}} command:

{{{
[defaults]
# suppress noisy extdiff header message
cdiff = -q

[extdiff]
cmd.cdiff = colordiff
opts.cdiff = -uprN
}}}

=== Using config substitution and the [DEFAULT] section of hgrc ===
The `hgrc` manpage gives a passing description of the `[DEFAULT]` section header but gives no notion of how one might use this (or the possible caveats). Here's an example:

 * `%(NAME)s` is substituted in configuration values if `NAME` is defined in the current section
 * Names defined in the `[DEFAULT]` section appear in all other configuration sections (unless overridden in a particular section)
 * In most sections, names not specifically used are ignored however...
 * The `[extensions]` will attempt to load any names in it has extensions
 * Putting a name in `[DEFAULT]` usually breaks the configuration as the name is likely not a valid extension
 * Placing a name under `[DEFAULT]` requires that you keep the `[extensions]` section from trying to load it.

Here's an example of the usage:

 {{{
[DEFAULT]
HOME = /home/myuser

[ui]
ignore.mine = %(HOME)s/.hgignore.mine
style = %(HOME)s/.hg-styles/hg-map-cmdline.color

[paths]
dotfiles = %(HOME)s/

[extensions]
# Avoid the [DEFAULT] extension bug
HOME = !
}}}

=== Using FileMerge.app/opendiff as the diff program (OS X) ===
The Developer Tools for OS X provide the excellent graphical diff program "File``Merge.app". The provided command-line wrapper "opendiff" for "File``Merge.app" will not work with ExtdiffExtension. Instead, use the script [http://ssel.vub.ac.be/ssel/internal:fmdiff fmdiff] which wraps "File``Merge.app" so that it responds like the usual diff program. Once fmdiff is in your path, just add the below to your .hgrc file
{{{
[extensions]
hgext.extdiff =

[extdiff]
cmd.opendiff = fmdiff
}}}
and use
{{{
$ hg opendiff ...
}}}

=== hg diff does not support -foo option like gnu diff does ===
I use the following bash function to put the diff options I like most

{{{
hgdi ()
{
  for i in `hg status -marn "$@"`
  do
    diff -ubwd <(hg cat "$i") "$i"
  done
}
}}}

You can also use the extdiff extension to call GNU diff from Mercurial.

=== Handling binary files ===
as stated in BinaryFiles, you need to have a tool which manages binary merge. Joachim Eibl's new kdiff3 version ships a version qt4 version (on windows called "kdiff3-QT4.exe") which recognizes binary files. Pressing "cancel" and "do not save" leaves you with the version of the file you have currently in the filesystem. See also on CvsConcepts.

=== Diagnose "abort: Error" messages ===

I get a cryptic "abort: Error" message while pushing to my server. This is not enough info to figure out the problem. I tried `hg -v --debug push` but I still don't get anything more informative. What can I do?

 * disable cgitb in hgweb on the server
 * run with `--debug --traceback` on the client
 * check the error logs on the server

=== Removing the working directory of a repository ===

If you forgot to specify {{{-U}}} on "hg [:Clone:clone]", doing
{{{
hg update null
}}}
will remove everything from the [:WorkingDirectory:working directory] of the [:Repository:repository]. See also [:Update:update]. ~-([http://selenic.com/pipermail/mercurial/2008-March/018332.html reference])-~

=== Setting the default context for diff to something larger ===

hg diff outputs 3 lines of context per default (see "hg help diff"). To change the default to for example 8 lines, add

{{{
[defaults]
diff = --unified 8
}}}

to the defaults section of your [:.hgrc]. However, this only affects the diff command itself. ~-([http://www.selenic.com/mercurial/bts/issue1076 reference])-~

Tips and Tricks

(see also [:FAQ], [:HOWTOs], [wiki:CategoryTipsAndTricks CategoryTipsAndTricks])

TableOfContents

Include(/Index)

1. Undo an "hg add"

hg revert # take out of source control
hg rm -f # remove it

On Unix, to revert just the pending adds, you can use

hg status -an0 | xargs -r0 hg revert

2. Save a push URL so that you don't need to enter it each time

It is possible to store a default [:Push:push] URL that will be used when you type just "hg push". Edit [:.hgrc:hgrc] and add something like:

[paths]
default-push = ssh://hg@example.com/path

3. Track changes to a repository with RSS

You can track changes to projects and individual files with RSS feeds from hgweb. Here are some examples:

If you want to create web links to [:Tag:tagged] or [:Tip:tip] versions of a [:Repository:repository] or a file, you can do so like this:

5. Configuring Mercurial

See in [:.hgrc].

6. Abbreviate command options

It is possible to abbreviate command options:

hg revert --no-b
hg revert --no-backup

7. Ignore files from Emacs/XEmacs

Add the following to [:.hgignore]:

syntax: glob
*~

syntax: regexp
(.*/)?\#[^/]*\#$

8. Make a clean copy of a source tree, like CVS export

hg clone source export
rm -rf export/.hg

or using the archive command

cd source
hg archive ../export

The same thing, but for a [:Tag:tagged] release:

hg clone --noupdate source export-tagged
cd export-tagged
hg update mytag
rm -rf .hg

or using the archive command

cd source
hg archive -r mytag ../export-tagged

9. One liner to remove unknown files with a pattern

To make these work, replace the ls -l with the command you wish to execute (ie. rm). You can also tweak the parameters passed to hg status to filter by something other than unknown files (see hg help status).

hg status -nu0 | grep -z pattern | xargs -0r ls -l

The above command requires a current version of GNU grep. If you don't have one, you can use the following:

hg status -nu | grep pattern | tr '\n' '\0' | xargs -0r ls -l

10. Generating color diff output with extdiff and colordiff

You can use the [:ExtdiffExtension:extdiff extension] to get colorized diff output. If you've enabled the extension and have colordiff installed, the following [:.hgrc:hgrc] snippet will create a new cdiff command:

[defaults]
# suppress noisy extdiff header message
cdiff = -q

[extdiff]
cmd.cdiff = colordiff
opts.cdiff = -uprN

11. Using config substitution and the [DEFAULT] section of hgrc

The hgrc manpage gives a passing description of the [DEFAULT] section header but gives no notion of how one might use this (or the possible caveats). Here's an example:

  • %(NAME)s is substituted in configuration values if NAME is defined in the current section

  • Names defined in the [DEFAULT] section appear in all other configuration sections (unless overridden in a particular section)

  • In most sections, names not specifically used are ignored however...
  • The [extensions] will attempt to load any names in it has extensions

  • Putting a name in [DEFAULT] usually breaks the configuration as the name is likely not a valid extension

  • Placing a name under [DEFAULT] requires that you keep the [extensions] section from trying to load it.

Here's an example of the usage:

  • [DEFAULT]
    HOME = /home/myuser
    
    [ui]
    ignore.mine = %(HOME)s/.hgignore.mine
    style = %(HOME)s/.hg-styles/hg-map-cmdline.color
    
    [paths]
    dotfiles = %(HOME)s/
    
    [extensions]
    # Avoid the [DEFAULT] extension bug
    HOME = !

12. Using FileMerge.app/opendiff as the diff program (OS X)

The Developer Tools for OS X provide the excellent graphical diff program "FileMerge.app". The provided command-line wrapper "opendiff" for "FileMerge.app" will not work with ExtdiffExtension. Instead, use the script [http://ssel.vub.ac.be/ssel/internal:fmdiff fmdiff] which wraps "FileMerge.app" so that it responds like the usual diff program. Once fmdiff is in your path, just add the below to your .hgrc file

[extensions]
hgext.extdiff =

[extdiff]
cmd.opendiff =  fmdiff

and use

$ hg opendiff ...

13. hg diff does not support -foo option like gnu diff does

I use the following bash function to put the diff options I like most

hgdi ()
{
  for i in `hg status -marn "$@"`
  do
    diff -ubwd <(hg cat "$i") "$i"
  done
}

You can also use the extdiff extension to call GNU diff from Mercurial.

14. Handling binary files

as stated in BinaryFiles, you need to have a tool which manages binary merge. Joachim Eibl's new kdiff3 version ships a version qt4 version (on windows called "kdiff3-QT4.exe") which recognizes binary files. Pressing "cancel" and "do not save" leaves you with the version of the file you have currently in the filesystem. See also on CvsConcepts.

15. Diagnose "abort: Error" messages

I get a cryptic "abort: Error" message while pushing to my server. This is not enough info to figure out the problem. I tried hg -v --debug push but I still don't get anything more informative. What can I do?

  • disable cgitb in hgweb on the server
  • run with --debug --traceback on the client

  • check the error logs on the server

16. Removing the working directory of a repository

If you forgot to specify -U on "hg [:Clone:clone]", doing

hg update null

will remove everything from the [:WorkingDirectory:working directory] of the [:Repository:repository]. See also [:Update:update]. ([http://selenic.com/pipermail/mercurial/2008-March/018332.html reference])

17. Setting the default context for diff to something larger

hg diff outputs 3 lines of context per default (see "hg help diff"). To change the default to for example 8 lines, add

[defaults]
diff = --unified 8

to the defaults section of your [:.hgrc]. However, this only affects the diff command itself. ([http://www.selenic.com/mercurial/bts/issue1076 reference])

TipsAndTricks (last edited 2016-12-05 11:14:36 by ArneBab)