Login
Hex Artifact Content
Login

Artifact 82455034046d0f9232af266932bc62e7ed330442:

Attachment "testfossil.sh" to ticket [ffa87168ce] added by ron 2011-06-15 03:45:53.
0000: 23 21 2f 62 69 6e 2f 62 61 73 68 0a 0a 72 65 70  #!/bin/bash..rep
0010: 6f 3d 27 74 65 73 74 2e 66 6f 73 73 69 6c 27 0a  o='test.fossil'.
0020: 61 64 6d 69 6e 3d 27 74 65 73 74 65 72 27 0a 23  admin='tester'.#
0030: 20 63 6c 65 61 6e 20 75 70 3a 0a 72 6d 20 2d 72   clean up:.rm -r
0040: 66 20 66 6f 73 73 69 6c 20 70 72 6f 6a 20 20 22  f fossil proj  "
0050: 24 72 65 70 6f 22 0a 0a 23 20 63 72 65 61 74 65  $repo"..# create
0060: 20 74 68 65 20 69 6e 66 72 61 73 74 72 75 63 74   the infrastruct
0070: 75 72 65 3a 0a 6d 6b 64 69 72 20 66 6f 73 73 69  ure:.mkdir fossi
0080: 6c 0a 6d 6b 64 69 72 20 70 72 6f 6a 0a 0a 23 20  l.mkdir proj..# 
0090: 63 72 65 61 74 65 20 74 68 65 20 66 6f 73 73 69  create the fossi
00a0: 6c 0a 66 6f 73 73 69 6c 20 6e 65 77 20 2d 2d 61  l.fossil new --a
00b0: 64 6d 69 6e 2d 75 73 65 72 20 22 24 61 64 6d 69  dmin-user "$admi
00c0: 6e 22 20 22 24 72 65 70 6f 22 0a 23 20 72 75 6e  n" "$repo".# run
00d0: 20 74 68 65 20 73 65 72 76 65 72 3a 0a 66 6f 73   the server:.fos
00e0: 73 69 6c 20 73 65 72 76 65 72 20 22 24 72 65 70  sil server "$rep
00f0: 6f 22 20 26 0a 0a 23 20 63 6c 6f 6e 65 20 69 74  o" &..# clone it
0100: 0a 28 0a 09 63 64 20 66 6f 73 73 69 6c 0a 09 66  .(..cd fossil..f
0110: 6f 73 73 69 6c 20 63 6c 6f 6e 65 20 22 68 74 74  ossil clone "htt
0120: 70 3a 2f 2f 24 61 64 6d 69 6e 40 6c 6f 63 61 6c  p://$admin@local
0130: 68 6f 73 74 3a 38 30 38 30 2f 22 20 20 22 24 72  host:8080/"  "$r
0140: 65 70 6f 2e 63 6c 6f 6e 65 22 0a 29 0a 0a 23 20  epo.clone".)..# 
0150: 75 70 64 61 74 65 20 69 74 0a 28 0a 09 63 64 20  update it.(..cd 
0160: 70 72 6f 6a 0a 09 66 6f 73 73 69 6c 20 6f 70 65  proj..fossil ope
0170: 6e 20 22 2e 2e 2f 66 6f 73 73 69 6c 2f 24 72 65  n "../fossil/$re
0180: 70 6f 2e 63 6c 6f 6e 65 22 0a 09 66 6f 73 73 69  po.clone"..fossi
0190: 6c 20 75 70 64 0a 29 0a 0a 23 20 67 6f 6f 64 2d  l upd.)..# good-
01a0: 62 79 20 73 65 72 76 65 72 3a 0a 6b 69 6c 6c 20  by server:.kill 
01b0: 25 31 0a                                         %1.