hgext/purge/README
author Thomas Arendsen Hein <thomas@intevation.de>
Thu, 01 Jun 2006 23:58:06 +0200
changeset 2379 e90cff87f871
parent 2368 README@eb1ec13e3b0d
child 2381 ab7a438294fc
permissions -rw-r--r--
Reorganized files in hg-purge repo to push them into Mercurial. README -> hgext/purge/README purge.py -> hgext/purge/__init__.py removed COPYING.GPL and .hgignore (already in the Mercurial repo)
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2364
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
     1
What is "hg purge"?
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
     2
===================
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
     3
"purge" is a simple extension for the Mercurial source control management
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
     4
system (http://www.selenic.com/mercurial).
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
     5
This extension adds a "purge" command to "hg" that removes files not known
2368
eb1ec13e3b0d Added a link to the home page of hg purge
demian@gaudron.lan
parents: 2367
diff changeset
     6
to Mercurial, this is useful to test local and uncommitted changes in the
2364
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
     7
otherwise clean source tree.
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
     8
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
     9
This means that Mercurial will delete:
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    10
 - Unknown files: files marked with "?" by "hg status"
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    11
 - Ignored files: files usually ignored by Mercurial because they match a
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    12
   pattern in a ".hgignore" file
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    13
 - Empty directories: infact Mercurial ignores directories unless they
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    14
   contain files under source control managment
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    15
But it will leave untouched:
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    16
 - Unmodified files tracked by Mercurial
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    17
 - Modified files tracked by Mercurial
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    18
 - New files added to the repository (with "hg add")
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    19
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    20
Be careful with "hg purge", you could irreversibly delete some files you
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    21
forgot to add to the repository. If you only want to print the list of
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    22
files that this program would delete use:
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    23
  hg purge -vn
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    24
2368
eb1ec13e3b0d Added a link to the home page of hg purge
demian@gaudron.lan
parents: 2367
diff changeset
    25
To get the most recent version of "hg purge" visit its home page:
eb1ec13e3b0d Added a link to the home page of hg purge
demian@gaudron.lan
parents: 2367
diff changeset
    26
  http://www.barisione.org/apps.html#hg-purge
eb1ec13e3b0d Added a link to the home page of hg purge
demian@gaudron.lan
parents: 2367
diff changeset
    27
eb1ec13e3b0d Added a link to the home page of hg purge
demian@gaudron.lan
parents: 2367
diff changeset
    28
This program was inspired by the "cvspurge" script contained in CVS utilities
2367
8c893af1154a Added a link to the page for CVS utilities
demian@gaudron.lan
parents: 2366
diff changeset
    29
(http://www.red-bean.com/cvsutils/).
8c893af1154a Added a link to the page for CVS utilities
demian@gaudron.lan
parents: 2366
diff changeset
    30
2364
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    31
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    32
How to install
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    33
==============
2366
f9f53c7e1875 Added some lines on the requirements for purge
demian@gaudron.lan
parents: 2365
diff changeset
    34
Obviously you need an installed version of Mercurial to use this extension.
f9f53c7e1875 Added some lines on the requirements for purge
demian@gaudron.lan
parents: 2365
diff changeset
    35
"purge" has been tested with Mercurial 0.8.1 and 0.9 but it may work with
f9f53c7e1875 Added some lines on the requirements for purge
demian@gaudron.lan
parents: 2365
diff changeset
    36
other versions as well.
f9f53c7e1875 Added some lines on the requirements for purge
demian@gaudron.lan
parents: 2365
diff changeset
    37
2365
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    38
Put the "purge.py" file in a directory of your choice. Enable the extension
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    39
inserting an instruction like "purge=/path/you/choose/purge.py" in the
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    40
"[extensions]" section of a configuration file read by "hg".
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    41
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    42
For instance if you installed the script in "/home/USER/hg-purge/", you
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    43
can create a file named  ".hgrc" in your home directory with the following
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    44
content:
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    45
  [extensions]
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    46
  purge=/home/USER/hg-purge/purge.py
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    47
Note that using "~/USER/hg-purge/purge.py" does not work with hg 0.9.
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    48
a5d2e5490ac7 Added an explanation on how to enable the extension in "~/.hgrc"
demian@gaudron.lan
parents: 2364
diff changeset
    49
For more information on the configuration files see the man page for "hgrc":
2364
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    50
  man 5 hgrc
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    51
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    52
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    53
How to use "hg purge"
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    54
====================
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    55
For help on the usage of "hg purge" use:
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    56
  hg help purge
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    57
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    58
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    59
License
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    60
=======
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    61
Copyright (C) 2006 - Marco Barisione <marco@barisione.org>
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    62
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    63
This program is distributed in the hope that it will be useful,
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    64
but WITHOUT ANY WARRANTY; without even the implied warranty of
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    65
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    66
GNU General Public License for more details.
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    67
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    68
A copy of the GNU General Public License is distributed along
f368a1c302d5 Initial commit
demian@gaudron.lan
parents:
diff changeset
    69
with this program in the file COPYING.GPL.