hgbook

view en/examples/tour @ 93:97638d862ef3

Network bits.
author Bryan O'Sullivan <bos@serpentine.com>
date Thu Oct 12 16:27:00 2006 -0700 (2006-10-12)
parents 72d207927dc4
children 0b97b0bdc830
line source
1 #!/bin/bash
3 #$ name: version
5 hg version
7 #$ name: help
9 hg help init
11 #$ name: clone
13 hg clone http://hg.serpentine.com/tutorial/hello
15 #$ name: ls
17 ls -l
18 ls hello
20 #$ name: ls-a
22 cd hello
23 ls -a
25 #$ name: log
27 hg log
29 #$ name: log-r
31 hg log -r 3
32 hg log -r ff5d7b70a2a9
33 hg log -r 1 -r 4
35 #$ name: log.range
37 hg log -r 2:4
39 #$ name: log-v
41 hg log -v -r 3
43 #$ name: log-vp
45 hg log -v -p -r 2
47 #$ name: reclone
49 cd ..
50 hg clone hello my-hello
51 cd my-hello
53 #$ name: sed
55 sed -i '/printf/a\\tprintf("hello again!\\n");' hello.c
57 #$ name: status
59 ls
60 hg status
62 #$ name: diff
64 hg diff
66 #$ name:
68 export HGEDITOR='echo Added an extra line of output >'
70 #$ name: commit
72 hg commit
74 #$ name: tip
76 hg tip -vp
78 #$ name: clone-pull
80 cd ..
81 hg clone hello hello-pull
83 #$ name: incoming
85 cd hello-pull
86 hg incoming ../my-hello
88 #$ name: pull
90 hg tip
91 hg pull ../my-hello
92 hg tip
94 #$ name: update
96 grep printf hello.c
97 hg update tip
98 grep printf hello.c
100 #$ name: parents
102 hg parents
104 #$ name: older
106 hg update 2
107 hg parents
109 #$ name: clone-push
111 cd ..
112 hg clone hello hello-push
114 #$ name: outgoing
116 cd my-hello
117 hg outgoing ../hello-push
119 #$ name: push
121 hg push ../hello-push
123 #$ name: push.nothing
125 hg push ../hello-push
127 #$ name: outgoing.net
129 hg outgoing http://hg.serpentine.com/tutorial/hello
131 #$ name: push.net
133 hg push http://hg.serpentine.com/tutorial/hello
135 #$ name:
136 exit 0