Mercurial > hg
annotate README @ 3579:0ed2732aa393
Explicitly use REVLOGV0 instead of 0 in bundlerepo.
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Sun, 29 Oct 2006 10:55:38 +0100 |
parents | 72efff4be2ad |
children | 25e549e9b7d0 |
rev | line source |
---|---|
445 | 1 MERCURIAL QUICK-START |
2 | |
204
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
3 Setting up Mercurial: |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
4 |
204
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
5 Note: some distributions fails to include bits of distutils by |
205
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
6 default, you'll need python-dev to install. You'll also need a C |
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
7 compiler and a 3-way merge tool like merge, tkdiff, or kdiff3. |
204
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
8 |
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
9 First, unpack the source: |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
10 |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
11 $ tar xvzf mercurial-<ver>.tar.gz |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
12 $ cd mercurial-<ver> |
204
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
13 |
2208 | 14 When installing, change python to python2.3 or python2.4 if 2.2 is the |
15 default on your system. | |
16 | |
205
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
17 To install system-wide: |
204
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
18 |
2208 | 19 $ python setup.py install --force |
204
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
20 |
205
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
21 To install in your home directory (~/bin and ~/lib, actually), run: |
204
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
22 |
2208 | 23 $ python setup.py install --home=${HOME} --force |
507 | 24 $ export PYTHONPATH=${HOME}/lib/python # (or lib64/ on some systems) |
25 $ export PATH=${HOME}/bin:$PATH # add these to your .bashrc | |
205
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
26 |
204
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
27 And finally: |
161cef501e8d
README: integrate various changes and suggestions from Rafael Villar Burke
mpm@selenic.com
parents:
182
diff
changeset
|
28 |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
29 $ hg # test installation, show help |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
30 |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
31 If you get complaints about missing modules, you probably haven't set |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
32 PYTHONPATH correctly. |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
33 |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
34 Setting up a Mercurial project: |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
35 |
2208 | 36 $ hg init project # creates project directory |
37 $ cd project | |
38 # copy files in, edit them | |
39 $ hg add # add all unknown files | |
40 $ hg commit # commit all changes, edit changelog entry | |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
41 |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
42 Mercurial will look for a file named .hgignore in the root of your |
633
f597539c7abd
Slim down and update README a bit
Matt Mackall <mpm@selenic.com>
parents:
631
diff
changeset
|
43 repository which contains a set of regular expressions to ignore in |
f597539c7abd
Slim down and update README a bit
Matt Mackall <mpm@selenic.com>
parents:
631
diff
changeset
|
44 file paths. |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
45 |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
46 Branching and merging: |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
47 |
3507 | 48 $ hg clone project project-work # create a new branch |
49 $ cd project-work | |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
50 $ <make changes> |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
51 $ hg commit |
3507 | 52 $ cd ../project |
53 $ hg pull ../project-work # pull changesets from project-work | |
54 $ hg merge # merge the new tip from project-work into | |
261 | 55 # our working directory |
633
f597539c7abd
Slim down and update README a bit
Matt Mackall <mpm@selenic.com>
parents:
631
diff
changeset
|
56 $ hg commit # commit the result of the merge |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
57 |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
58 Importing patches: |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
59 |
3507 | 60 Simple: |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
61 $ patch < ../p/foo.patch |
2208 | 62 $ hg commit -A |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
63 |
3507 | 64 Fast: |
1308
2073e5a71008
Cleanup of tabs and trailing spaces.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
981
diff
changeset
|
65 $ cat ../p/patchlist | xargs hg import -p1 -b ../p |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
66 |
205
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
67 Exporting a patch: |
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
68 |
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
69 (make changes) |
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
70 $ hg commit |
3507 | 71 $ hg export tip > foo.patch # export latest change |
205
d255d99a7cbd
README: integrate some changes from Kevin Smith
mpm@selenic.com
parents:
204
diff
changeset
|
72 |
63 | 73 Network support: |
74 | |
445 | 75 # pull from the primary Mercurial repo |
1308
2073e5a71008
Cleanup of tabs and trailing spaces.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
981
diff
changeset
|
76 foo$ hg clone http://selenic.com/hg/ |
633
f597539c7abd
Slim down and update README a bit
Matt Mackall <mpm@selenic.com>
parents:
631
diff
changeset
|
77 foo$ cd hg |
1
273ce12ad8f1
Update README to discuss remote pull, rsync, and the hg repo
mpm@selenic.com
parents:
0
diff
changeset
|
78 |
160 | 79 # export your current repo via HTTP with browsable interface |
80 foo$ hg serve -n "My repo" -p 80 | |
1308
2073e5a71008
Cleanup of tabs and trailing spaces.
Thomas Arendsen Hein <thomas@intevation.de>
parents:
981
diff
changeset
|
81 |
327 | 82 # pushing changes to a remote repo with SSH |
83 foo$ hg push ssh://user@example.com/~/hg/ | |
84 | |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
85 # merge changes from a remote machine |
261 | 86 bar$ hg pull http://foo/ |
2208 | 87 bar$ hg merge # merge changes into your working directory |
63 | 88 |
160 | 89 # Set up a CGI server on your webserver |
445 | 90 foo$ cp hgweb.cgi ~/public_html/hg/index.cgi |
91 foo$ emacs ~/public_html/hg/index.cgi # adjust the defaults | |
969 | 92 |
93 For more info: | |
94 | |
95 Documentation in doc/ | |
96 Mercurial website at http://selenic.com/mercurial |