hgbook

view en/examples/ch01/new @ 807:9fac10e1b760

Minor changes and translation of code snippets for App.C.
author Giulio@puck
date Sat Aug 15 03:45:43 2009 +0200 (2009-08-15)
parents
children
line source
1 #!/bin/bash
3 cat > hello.c <<EOF
4 int main()
5 {
6 printf("hello world!\n");
7 }
8 EOF
10 cat > goodbye.c <<EOF
11 int main()
12 {
13 printf("goodbye world!\n");
14 }
15 EOF
17 #$ name: init
19 hg init myproject
21 #$ name: ls
23 ls -l
25 #$ name: ls2
27 ls -al myproject
29 #$ name: add
31 cd myproject
32 cp ../hello.c .
33 cp ../goodbye.c .
34 hg add
35 hg status
37 #$ name: commit
39 hg commit -m 'Initial commit'