Hex Artifact Content
Not logged in

Artifact 0f60ddea661df55dbdb9203c4dcd5628522b0a06:

File www/newrepo.wiki part of check-in [766bec08ce] - Documentation tweaks. Change the "Setup" menu title to "Admin". Added pages under Admin to view the RCVFROM table of the database. by drh on 2009-01-25 19:18:09.

0000: 3c 68 31 3e 48 4f 57 54 4f 3a 20 63 72 65 61 74  <h1>HOWTO: creat
0010: 69 6e 67 20 61 20 6e 65 77 20 72 65 70 6f 73 69  ing a new reposi
0020: 74 6f 72 79 3c 2f 68 31 3e 0a 0a 3c 70 3e 20 54  tory</h1>..<p> T
0030: 68 65 20 5b 2f 64 6f 63 2f 74 69 70 2f 77 77 77  he [/doc/tip/www
0040: 2f 71 75 69 63 6b 73 74 61 72 74 2e 77 69 6b 69  /quickstart.wiki
0050: 7c 71 75 69 63 6b 73 74 61 72 74 20 67 75 69 64  |quickstart guid
0060: 65 5d 20 65 78 70 6c 61 69 6e 73 20 68 6f 77 0a  e] explains how.
0070: 74 6f 20 67 65 74 20 75 70 20 61 6e 64 20 72 75  to get up and ru
0080: 6e 6e 69 6e 67 20 77 69 74 68 20 66 6f 73 73 69  nning with fossi
0090: 6c 2e 20 42 75 74 20 6f 6e 63 65 20 79 6f 75 27  l. But once you'
00a0: 72 65 20 72 75 6e 6e 69 6e 67 2c 20 77 68 61 74  re running, what
00b0: 20 63 61 6e 0a 79 6f 75 20 64 6f 20 77 69 74 68   can.you do with
00c0: 20 69 74 3f 20 54 68 69 73 20 64 6f 63 75 6d 65   it? This docume
00d0: 6e 74 20 77 69 6c 6c 20 77 61 6c 6b 20 79 6f 75  nt will walk you
00e0: 20 74 68 72 6f 75 67 68 20 74 68 65 20 70 72 6f   through the pro
00f0: 63 65 73 73 20 6f 66 0a 63 72 65 61 74 69 6e 67  cess of.creating
0100: 20 61 20 66 6f 73 73 69 6c 20 72 65 70 6f 73 69   a fossil reposi
0110: 74 6f 72 79 2c 20 70 6f 70 75 6c 61 74 69 6e 67  tory, populating
0120: 20 69 74 20 77 69 74 68 20 66 69 6c 65 73 2c 20   it with files, 
0130: 61 6e 64 20 74 68 65 6e 0a 73 68 61 72 69 6e 67  and then.sharing
0140: 20 69 74 20 6f 76 65 72 20 74 68 65 20 77 65 62   it over the web
0150: 2e 3c 2f 70 3e 0a 0a 54 68 65 20 66 69 72 73 74  .</p>..The first
0160: 20 74 68 69 6e 67 20 77 65 20 6e 65 65 64 20 74   thing we need t
0170: 6f 20 64 6f 20 69 73 20 63 72 65 61 74 65 20 61  o do is create a
0180: 20 66 6f 73 73 69 6c 20 72 65 70 6f 73 69 74 6f   fossil reposito
0190: 72 79 20 66 69 6c 65 3a 0a 0a 3c 76 65 72 62 61  ry file:..<verba
01a0: 74 69 6d 3e 0a 73 74 65 70 68 61 6e 40 6c 75 64  tim>.stephan@lud
01b0: 6f 3a 7e 2f 66 6f 73 73 69 6c 24 20 66 6f 73 73  o:~/fossil$ foss
01c0: 69 6c 20 6e 65 77 20 64 65 6d 6f 2e 66 6f 73 73  il new demo.foss
01d0: 69 6c 0a 70 72 6f 6a 65 63 74 2d 69 64 3a 20 39  il.project-id: 9
01e0: 64 38 63 63 66 66 35 36 37 31 37 39 36 65 65 30  d8ccff5671796ee0
01f0: 34 65 36 30 61 66 36 39 33 32 61 61 37 37 38 38  4e60af6932aa7788
0200: 66 30 61 39 39 30 61 0a 73 65 72 76 65 72 2d 69  f0a990a.server-i
0210: 64 3a 20 20 31 34 35 66 65 37 64 37 31 65 33 62  d:  145fe7d71e3b
0220: 35 31 33 61 63 33 37 61 63 32 38 33 39 37 39 64  513ac37ac283979d
0230: 37 33 65 31 32 63 61 30 34 62 66 65 0a 61 64 6d  73e12ca04bfe.adm
0240: 69 6e 2d 75 73 65 72 3a 20 73 74 65 70 68 61 6e  in-user: stephan
0250: 20 28 69 6e 69 74 69 61 6c 20 70 61 73 73 77 6f   (initial passwo
0260: 72 64 20 69 73 20 2a 2a 2a 2a 2a 2a 29 0a 3c 2f  rd is ******).</
0270: 76 65 72 62 61 74 69 6d 3e 0a 0a 54 68 65 20 6e  verbatim>..The n
0280: 75 6d 62 65 72 73 20 69 74 20 73 70 69 74 73 20  umbers it spits 
0290: 6f 75 74 20 61 72 65 20 75 6e 69 6d 70 6f 72 74  out are unimport
02a0: 61 6e 74 20 28 74 68 65 79 20 61 72 65 20 76 65  ant (they are ve
02b0: 72 73 69 6f 6e 0a 6e 75 6d 62 65 72 73 29 2e 0a  rsion.numbers)..
02c0: 0a 4e 6f 77 20 77 65 20 68 61 76 65 20 61 6e 20  .Now we have an 
02d0: 65 6d 70 74 79 20 72 65 70 6f 73 69 74 6f 72 79  empty repository
02e0: 20 66 69 6c 65 20 6e 61 6d 65 64 20 3c 74 74 3e   file named <tt>
02f0: 64 65 6d 6f 2e 66 6f 73 73 69 6c 3c 2f 74 74 3e  demo.fossil</tt>
0300: 2e 0a 54 68 65 72 65 20 69 73 20 6e 6f 74 68 69  ..There is nothi
0310: 6e 67 20 6d 61 67 69 63 61 6c 20 61 62 6f 75 74  ng magical about
0320: 20 74 68 65 20 65 78 74 65 6e 73 69 6f 6e 20 3c   the extension <
0330: 74 74 3e 2e 66 6f 73 73 69 6c 3c 2f 74 74 3e 20  tt>.fossil</tt> 
0340: 2d 20 69 74 27 73 0a 6a 75 73 74 20 61 20 63 6f  - it's.just a co
0350: 6e 76 65 6e 74 69 6f 6e 2e 20 59 6f 75 20 6d 61  nvention. You ma
0360: 79 20 6e 61 6d 65 20 79 6f 75 72 20 66 69 6c 65  y name your file
0370: 73 20 61 6e 79 74 68 69 6e 67 20 79 6f 75 20 6c  s anything you l
0380: 69 6b 65 2e 0a 0a 54 68 65 20 66 69 72 73 74 20  ike...The first 
0390: 74 68 69 6e 67 20 77 65 20 6e 6f 72 6d 61 6c 6c  thing we normall
03a0: 79 20 77 61 6e 74 20 74 6f 20 64 6f 20 69 73 20  y want to do is 
03b0: 74 6f 20 72 75 6e 20 66 6f 73 73 69 6c 20 61 73  to run fossil as
03c0: 20 61 20 6c 6f 63 61 6c 20 73 65 72 76 65 72 20   a local server 
03d0: 73 6f 0a 74 68 61 74 20 79 6f 75 20 63 61 6e 20  so.that you can 
03e0: 63 6f 6e 66 69 67 75 72 65 20 74 68 65 20 61 63  configure the ac
03f0: 63 65 73 73 20 72 69 67 68 74 73 20 74 6f 20 74  cess rights to t
0400: 68 65 20 72 65 70 6f 3a 0a 0a 3c 76 65 72 62 61  he repo:..<verba
0410: 74 69 6d 3e 0a 73 74 65 70 68 61 6e 40 6c 75 64  tim>.stephan@lud
0420: 6f 3a 7e 2f 66 6f 73 73 69 6c 24 20 66 6f 73 73  o:~/fossil$ foss
0430: 69 6c 20 75 69 20 64 65 6d 6f 2e 66 6f 73 73 69  il ui demo.fossi
0440: 6c 0a 3c 2f 76 65 72 62 61 74 69 6d 3e 0a 0a 54  l.</verbatim>..T
0450: 68 65 20 3c 74 74 3e 75 69 3c 2f 74 74 3e 20 63  he <tt>ui</tt> c
0460: 6f 6d 6d 61 6e 64 20 73 74 61 72 74 73 20 75 70  ommand starts up
0470: 20 61 20 73 65 72 76 65 72 20 28 77 69 74 68 20   a server (with 
0480: 61 6e 20 6f 70 74 69 6f 6e 61 6c 20 3c 74 74 3e  an optional <tt>
0490: 2d 70 6f 72 74 0a 4e 55 4d 42 45 52 3c 2f 74 74  -port.NUMBER</tt
04a0: 3e 20 61 72 67 75 6d 65 6e 74 29 20 61 6e 64 20  > argument) and 
04b0: 6c 61 75 6e 63 68 65 73 20 61 20 77 65 62 20 62  launches a web b
04c0: 72 6f 77 73 65 72 20 70 6f 69 6e 74 69 6e 67 20  rowser pointing 
04d0: 61 74 20 74 68 65 0a 66 6f 73 73 69 6c 20 73 65  at the.fossil se
04e0: 72 76 65 72 2e 20 46 72 6f 6d 20 74 68 65 72 65  rver. From there
04f0: 20 69 74 20 74 61 6b 65 73 20 6a 75 73 74 20 61   it takes just a
0500: 20 66 65 77 20 6d 6f 6d 65 6e 74 73 20 74 6f 20   few moments to 
0510: 63 6f 6e 66 69 67 75 72 65 20 74 68 65 0a 72 65  configure the.re
0520: 70 6f 2e 20 4d 6f 73 74 20 69 6d 70 6f 72 74 61  po. Most importa
0530: 6e 74 6c 79 2c 20 67 6f 20 74 6f 20 74 68 65 20  ntly, go to the 
0540: 41 64 6d 69 6e 20 6d 65 6e 75 2c 20 74 68 65 6e  Admin menu, then
0550: 20 74 68 65 20 55 73 65 72 73 20 6c 69 6e 6b 2c   the Users link,
0560: 20 61 6e 64 0a 73 65 74 20 79 6f 75 72 20 61 63   and.set your ac
0570: 63 6f 75 6e 74 20 6e 61 6d 65 20 61 6e 64 20 70  count name and p
0580: 61 73 73 77 6f 72 64 2c 20 61 6e 64 20 67 72 61  assword, and gra
0590: 6e 74 20 79 6f 75 72 20 61 63 63 6f 75 6e 74 20  nt your account 
05a0: 61 6c 6c 20 61 63 63 65 73 73 0a 70 72 69 76 69  all access.privi
05b0: 6c 65 64 67 65 73 2e 20 28 49 20 61 6c 73 6f 20  ledges. (I also 
05c0: 6c 69 6b 65 20 74 6f 20 67 72 61 6e 74 20 43 6c  like to grant Cl
05d0: 6f 6e 65 20 61 63 63 65 73 73 20 74 6f 20 74 68  one access to th
05e0: 65 20 61 6e 6f 6e 79 6d 6f 75 73 20 75 73 65 72  e anonymous user
05f0: 2c 0a 62 75 74 20 74 68 61 74 27 73 20 70 65 72  ,.but that's per
0600: 73 6f 6e 61 6c 20 70 72 65 66 65 72 65 6e 63 65  sonal preference
0610: 2e 29 0a 0a 4f 6e 63 65 20 79 6f 75 20 61 72 65  .)..Once you are
0620: 20 64 6f 6e 65 2c 20 6b 69 6c 6c 20 74 68 65 20   done, kill the 
0630: 66 6f 73 73 69 6c 20 73 65 72 76 65 72 20 28 77  fossil server (w
0640: 69 74 68 20 43 74 72 6c 2d 43 20 6f 72 20 65 71  ith Ctrl-C or eq
0650: 75 69 76 61 6c 65 6e 74 29 0a 61 6e 64 20 63 6c  uivalent).and cl
0660: 6f 73 65 20 74 68 65 20 62 72 6f 77 73 65 72 20  ose the browser 
0670: 77 69 6e 64 6f 77 2e 0a 0a 3c 62 6c 6f 63 6b 71  window...<blockq
0680: 75 6f 74 65 3e 0a 54 69 70 3a 20 69 74 20 69 73  uote>.Tip: it is
0690: 20 6e 6f 74 20 73 74 72 69 63 74 6c 79 20 72 65   not strictly re
06a0: 71 75 69 72 65 64 20 74 6f 20 63 6f 6e 66 69 67  quired to config
06b0: 75 72 65 20 61 20 72 65 70 6f 73 69 74 6f 72 79  ure a repository
06c0: 0a 74 68 69 73 20 77 61 79 2c 20 62 75 74 20 69  .this way, but i
06d0: 66 20 79 6f 75 20 61 72 65 20 67 6f 69 6e 67 20  f you are going 
06e0: 74 6f 20 73 68 61 72 65 20 61 20 72 65 70 6f 20  to share a repo 
06f0: 6f 76 65 72 20 74 68 65 20 6e 65 74 20 74 68 65  over the net the
0700: 6e 20 69 74 0a 69 73 20 68 69 67 68 6c 79 20 72  n it.is highly r
0710: 65 63 6f 6d 6d 65 6e 64 65 64 2e 20 49 66 20 79  ecommended. If y
0720: 6f 75 20 61 72 65 20 6f 6e 6c 79 20 67 6f 69 6e  ou are only goin
0730: 67 20 74 6f 20 77 6f 72 6b 20 77 69 74 68 20 74  g to work with t
0740: 68 65 20 72 65 70 6f 0a 6c 6f 63 61 6c 6c 79 2c  he repo.locally,
0750: 20 79 6f 75 20 63 61 6e 20 73 6b 69 70 20 74 68   you can skip th
0760: 65 20 63 6f 6e 66 69 67 75 72 61 74 69 6f 6e 20  e configuration 
0770: 73 74 65 70 20 61 6e 64 20 64 6f 20 69 74 20 6c  step and do it l
0780: 61 74 65 72 20 69 66 0a 79 6f 75 20 64 65 63 69  ater if.you deci
0790: 64 65 20 79 6f 75 20 77 61 6e 74 20 74 6f 20 73  de you want to s
07a0: 68 61 72 65 20 79 6f 75 72 20 72 65 70 6f 2e 0a  hare your repo..
07b0: 3c 2f 62 6c 6f 63 6b 71 75 6f 74 65 3e 0a 0a 54  </blockquote>..T
07c0: 68 65 20 6e 65 78 74 20 74 68 69 6e 67 20 77 65  he next thing we
07d0: 20 6e 65 65 64 20 74 6f 20 64 6f 20 69 73 20 3c   need to do is <
07e0: 65 6d 3e 6f 70 65 6e 3c 2f 65 6d 3e 20 74 68 65  em>open</em> the
07f0: 20 72 65 70 6f 73 69 74 6f 72 79 2e 20 54 6f 20   repository. To 
0800: 64 6f 20 73 6f 0a 77 65 20 63 72 65 61 74 65 20  do so.we create 
0810: 61 20 77 6f 72 6b 69 6e 67 20 64 69 72 65 63 74  a working direct
0820: 6f 72 79 20 61 6e 64 20 74 68 65 6e 20 3c 74 74  ory and then <tt
0830: 3e 63 64 3c 2f 74 74 3e 20 74 6f 20 69 74 3a 0a  >cd</tt> to it:.
0840: 0a 3c 76 65 72 62 61 74 69 6d 3e 0a 73 74 65 70  .<verbatim>.step
0850: 68 61 6e 40 6c 75 64 6f 3a 7e 2f 66 6f 73 73 69  han@ludo:~/fossi
0860: 6c 24 20 6d 6b 64 69 72 20 64 65 6d 6f 0a 73 74  l$ mkdir demo.st
0870: 65 70 68 61 6e 40 6c 75 64 6f 3a 7e 2f 66 6f 73  ephan@ludo:~/fos
0880: 73 69 6c 24 20 63 64 20 64 65 6d 6f 0a 73 74 65  sil$ cd demo.ste
0890: 70 68 61 6e 40 6c 75 64 6f 3a 7e 2f 66 6f 73 73  phan@ludo:~/foss
08a0: 69 6c 2f 64 65 6d 6f 24 20 66 6f 73 73 69 6c 20  il/demo$ fossil 
08b0: 6f 70 65 6e 20 2e 2e 2f 64 65 6d 6f 2e 66 6f 73  open ../demo.fos
08c0: 73 69 6c 0a 73 74 65 70 68 61 6e 40 6c 75 64 6f  sil.stephan@ludo
08d0: 3a 7e 2f 66 6f 73 73 69 6c 2f 64 65 6d 6f 24 20  :~/fossil/demo$ 
08e0: 20 0a 3c 2f 76 65 72 62 61 74 69 6d 3e 0a 0a 54   .</verbatim>..T
08f0: 68 61 74 20 63 72 65 61 74 65 73 20 61 20 66 69  hat creates a fi
0900: 6c 65 20 63 61 6c 6c 65 64 20 3c 74 74 3e 5f 46  le called <tt>_F
0910: 4f 53 53 49 4c 5f 3c 2f 74 74 3e 20 69 6e 20 74  OSSIL_</tt> in t
0920: 68 65 20 63 75 72 72 65 6e 74 0a 64 69 72 65 63  he current.direc
0930: 74 6f 72 79 2c 20 61 6e 64 20 74 68 69 73 20 66  tory, and this f
0940: 69 6c 65 20 63 6f 6e 74 61 69 6e 73 20 61 6c 6c  ile contains all
0950: 20 6b 69 6e 64 73 20 6f 66 20 66 6f 73 73 69 6c   kinds of fossil
0960: 2d 72 65 6c 61 74 65 64 0a 69 6e 66 6f 72 6d 61  -related.informa
0970: 74 69 6f 6e 20 61 62 6f 75 74 20 79 6f 75 72 20  tion about your 
0980: 6c 6f 63 61 6c 20 72 65 70 6f 73 69 74 6f 72 79  local repository
0990: 2e 20 59 6f 75 20 63 61 6e 20 69 67 6e 6f 72 65  . You can ignore
09a0: 20 69 74 0a 66 6f 72 20 61 6c 6c 20 70 75 72 70   it.for all purp
09b0: 6f 73 65 73 2c 20 62 75 74 20 62 65 20 73 75 72  oses, but be sur
09c0: 65 20 6e 6f 74 20 74 6f 20 61 63 63 69 64 65 6e  e not to acciden
09d0: 74 61 6c 6c 79 20 72 65 6d 6f 76 65 20 69 74 0a  tally remove it.
09e0: 6f 72 20 6f 74 68 65 72 77 69 73 65 20 64 61 6d  or otherwise dam
09f0: 61 67 65 20 69 74 20 2d 20 69 74 20 62 65 6c 6f  age it - it belo
0a00: 6e 67 73 20 74 6f 20 66 6f 73 73 69 6c 2c 20 6e  ngs to fossil, n
0a10: 6f 74 20 79 6f 75 2e 0a 0a 54 68 65 20 6e 65 78  ot you...The nex
0a20: 74 20 74 68 69 6e 67 20 77 65 20 6e 65 65 64 20  t thing we need 
0a30: 74 6f 20 64 6f 20 69 73 20 61 64 64 20 66 69 6c  to do is add fil
0a40: 65 73 20 74 6f 20 6f 75 72 20 72 65 70 6f 73 69  es to our reposi
0a50: 74 6f 72 79 2e 20 20 41 73 20 69 74 0a 68 61 70  tory.  As it.hap
0a60: 70 65 6e 73 2c 20 77 65 20 68 61 76 65 20 61 20  pens, we have a 
0a70: 66 65 77 20 43 20 73 6f 75 72 63 65 20 66 69 6c  few C source fil
0a80: 65 73 20 6c 61 79 69 6e 67 20 61 72 6f 75 6e 64  es laying around
0a90: 2c 20 77 68 69 63 68 20 77 65 27 6c 6c 0a 73 69  , which we'll.si
0aa0: 6d 70 6c 79 20 63 6f 70 79 20 69 6e 74 6f 20 6f  mply copy into o
0ab0: 75 72 20 77 6f 72 6b 69 6e 67 20 64 69 72 65 63  ur working direc
0ac0: 74 6f 72 79 2e 0a 0a 3c 76 65 72 62 61 74 69 6d  tory...<verbatim
0ad0: 3e 0a 73 74 65 70 68 61 6e 40 6c 75 64 6f 3a 7e  >.stephan@ludo:~
0ae0: 2f 66 6f 73 73 69 6c 2f 64 65 6d 6f 24 20 63 70  /fossil/demo$ cp
0af0: 20 2e 2e 2f 63 73 6e 69 70 2f 2a 2e 7b 63 2c 68   ../csnip/*.{c,h
0b00: 7d 20 2e 0a 73 74 65 70 68 61 6e 40 6c 75 64 6f  } ..stephan@ludo
0b10: 3a 7e 2f 66 6f 73 73 69 6c 2f 64 65 6d 6f 24 20  :~/fossil/demo$ 
0b20: 6c 73 0a 63 6c 6f 62 2e 63 20 20 63 6c 6f 62 2e  ls.clob.c  clob.
0b30: 68 20 20 63 6c 6f 62 7a 2e 63 20 20 5f 46 4f 53  h  clobz.c  _FOS
0b40: 53 49 4c 5f 20 20 6d 6b 64 65 70 2e 63 20 20 74  SIL_  mkdep.c  t
0b50: 65 73 74 2d 63 6c 6f 62 2e 63 0a 74 6f 6b 65 6e  est-clob.c.token
0b60: 69 7a 65 5f 70 61 74 68 2e 63 20 74 6f 6b 65 6e  ize_path.c token
0b70: 69 7a 65 5f 70 61 74 68 2e 68 20 20 76 61 70 70  ize_path.h  vapp
0b80: 65 6e 64 66 2e 63 20 20 76 61 70 70 65 6e 64 66  endf.c  vappendf
0b90: 2e 68 0a 3c 2f 76 65 72 62 61 74 69 6d 3e 0a 0a  .h.</verbatim>..
0ba0: 46 6f 73 73 69 6c 20 64 6f 65 73 6e 27 74 20 6b  Fossil doesn't k
0bb0: 6e 6f 77 20 61 62 6f 75 74 20 74 68 6f 73 65 20  now about those 
0bc0: 66 69 6c 65 73 20 79 65 74 2e 20 54 65 6c 6c 69  files yet. Telli
0bd0: 6e 67 20 66 6f 73 73 69 6c 20 61 62 6f 75 74 0a  ng fossil about.
0be0: 61 20 6e 65 77 20 66 69 6c 65 20 69 73 20 61 20  a new file is a 
0bf0: 74 77 6f 2d 73 74 65 70 20 70 72 6f 63 65 73 73  two-step process
0c00: 2e 20 46 69 72 73 74 20 77 65 20 3c 65 6d 3e 61  . First we <em>a
0c10: 64 64 3c 2f 65 6d 3e 20 74 68 65 20 66 69 6c 65  dd</em> the file
0c20: 0a 74 6f 20 74 68 65 20 72 65 70 6f 2c 20 74 68  .to the repo, th
0c30: 65 6e 20 77 65 20 3c 65 6d 3e 63 6f 6d 6d 69 74  en we <em>commit
0c40: 3c 2f 65 6d 3e 20 74 68 65 20 66 69 6c 65 2e 20  </em> the file. 
0c50: 54 68 69 73 20 69 73 20 61 20 66 61 6d 69 6c 69  This is a famili
0c60: 61 72 0a 70 72 6f 63 65 73 73 20 66 6f 72 20 61  ar.process for a
0c70: 6e 79 6f 6e 65 20 77 68 6f 27 73 20 77 6f 72 6b  nyone who's work
0c80: 65 64 20 77 69 74 68 20 53 43 4d 20 73 79 73 74  ed with SCM syst
0c90: 65 6d 73 20 62 65 66 6f 72 65 3a 0a 0a 3c 76 65  ems before:..<ve
0ca0: 72 62 61 74 69 6d 3e 0a 73 74 65 70 68 61 6e 40  rbatim>.stephan@
0cb0: 6c 75 64 6f 3a 7e 2f 66 6f 73 73 69 6c 2f 64 65  ludo:~/fossil/de
0cc0: 6d 6f 24 20 66 6f 73 73 69 6c 20 61 64 64 20 2a  mo$ fossil add *
0cd0: 2e 7b 63 2c 68 7d 0a 73 74 65 70 68 61 6e 40 6c  .{c,h}.stephan@l
0ce0: 75 64 6f 3a 7e 2f 66 6f 73 73 69 6c 2f 64 65 6d  udo:~/fossil/dem
0cf0: 6f 24 20 66 6f 73 73 69 6c 20 63 6f 6d 6d 69 74  o$ fossil commit
0d00: 20 2d 6d 20 22 65 67 67 22 0a 4e 65 77 5f 56 65   -m "egg".New_Ve
0d10: 72 73 69 6f 6e 3a 20 64 31 32 39 36 62 34 61 30  rsion: d1296b4a0
0d20: 38 62 39 66 38 62 39 34 33 62 62 36 63 37 33 36  8b9f8b943bb6c736
0d30: 39 38 65 35 31 65 65 64 32 33 66 38 66 39 31 0a  98e51eed23f8f91.
0d40: 3c 2f 76 65 72 62 61 74 69 6d 3e 0a 0a 57 65 20  </verbatim>..We 
0d50: 6e 6f 77 20 68 61 76 65 20 61 20 77 6f 72 6b 69  now have a worki
0d60: 6e 67 20 72 65 70 6f 73 69 74 6f 72 79 21 20 54  ng repository! T
0d70: 68 65 20 66 69 6c 65 20 3c 74 74 3e 64 65 6d 6f  he file <tt>demo
0d80: 2e 66 6f 73 73 69 6c 3c 2f 74 74 3e 0a 69 73 20  .fossil</tt>.is 
0d90: 74 68 65 20 63 65 6e 74 72 61 6c 20 73 74 6f 72  the central stor
0da0: 61 67 65 2c 20 61 6e 64 20 77 65 20 63 61 6e 20  age, and we can 
0db0: 73 68 61 72 65 20 69 74 20 61 6d 6f 6e 67 73 74  share it amongst
0dc0: 20 61 6e 20 61 72 62 69 74 72 61 72 79 0a 6e 75   an arbitrary.nu
0dd0: 6d 62 65 72 20 6f 66 20 74 72 65 65 73 2e 20 41  mber of trees. A
0de0: 73 20 61 20 73 69 6c 6c 79 20 65 78 61 6d 70 6c  s a silly exampl
0df0: 65 3a 0a 0a 3c 76 65 72 62 61 74 69 6d 3e 0a 73  e:..<verbatim>.s
0e00: 74 65 70 68 61 6e 40 6c 75 64 6f 3a 7e 2f 66 6f  tephan@ludo:~/fo
0e10: 73 73 69 6c 2f 64 65 6d 6f 24 20 63 64 20 7e 2f  ssil/demo$ cd ~/
0e20: 66 6f 73 73 69 6c 0a 73 74 65 70 68 61 6e 40 6c  fossil.stephan@l
0e30: 75 64 6f 3a 7e 2f 66 6f 73 73 69 6c 24 20 6d 6b  udo:~/fossil$ mk
0e40: 64 69 72 20 64 65 6d 6f 32 0a 73 74 65 70 68 61  dir demo2.stepha
0e50: 6e 40 6c 75 64 6f 3a 7e 2f 66 6f 73 73 69 6c 24  n@ludo:~/fossil$
0e60: 20 63 64 20 64 65 6d 6f 32 0a 73 74 65 70 68 61   cd demo2.stepha
0e70: 6e 40 6c 75 64 6f 3a 7e 2f 66 6f 73 73 69 6c 2f  n@ludo:~/fossil/
0e80: 64 65 6d 6f 32 24 20 66 6f 73 73 69 6c 20 6f 70  demo2$ fossil op
0e90: 65 6e 20 2e 2e 2f 64 65 6d 6f 2e 66 6f 73 73 69  en ../demo.fossi
0ea0: 6c 0a 41 44 44 20 63 6c 6f 62 2e 63 0a 41 44 44  l.ADD clob.c.ADD
0eb0: 20 63 6c 6f 62 2e 68 0a 41 44 44 20 63 6c 6f 62   clob.h.ADD clob
0ec0: 7a 2e 63 0a 41 44 44 20 6d 6b 64 65 70 2e 63 0a  z.c.ADD mkdep.c.
0ed0: 41 44 44 20 74 65 73 74 2d 63 6c 6f 62 2e 63 0a  ADD test-clob.c.
0ee0: 41 44 44 20 74 6f 6b 65 6e 69 7a 65 5f 70 61 74  ADD tokenize_pat
0ef0: 68 2e 63 0a 41 44 44 20 74 6f 6b 65 6e 69 7a 65  h.c.ADD tokenize
0f00: 5f 70 61 74 68 2e 68 0a 41 44 44 20 76 61 70 70  _path.h.ADD vapp
0f10: 65 6e 64 66 2e 63 0a 3c 2f 76 65 72 62 61 74 69  endf.c.</verbati
0f20: 6d 3e 0a 0a 59 6f 75 20 6d 61 79 20 6d 6f 64 69  m>..You may modi
0f30: 66 79 20 74 68 65 20 72 65 70 6f 73 69 74 6f 72  fy the repositor
0f40: 79 20 28 65 2e 67 2e 20 61 64 64 2c 20 72 65 6d  y (e.g. add, rem
0f50: 6f 76 65 2c 20 6f 72 20 63 6f 6d 6d 69 74 20 66  ove, or commit f
0f60: 69 6c 65 73 29 20 66 72 6f 6d 0a 62 6f 74 68 20  iles) from.both 
0f70: 77 6f 72 6b 69 6e 67 20 64 69 72 65 63 74 6f 72  working director
0f80: 69 65 73 2c 20 61 6e 64 20 64 6f 69 6e 67 20 73  ies, and doing s
0f90: 6f 20 6d 69 67 68 74 20 62 65 20 75 73 65 66 75  o might be usefu
0fa0: 6c 20 77 68 65 6e 20 77 6f 72 6b 69 6e 67 20 6f  l when working o
0fb0: 6e 0a 61 20 62 72 61 6e 63 68 20 6f 72 20 65 78  n.a branch or ex
0fc0: 70 65 72 69 6d 65 6e 74 61 6c 20 63 6f 64 65 2e  perimental code.
0fd0: 0a 0a 4d 61 6b 69 6e 67 20 79 6f 75 72 20 72 65  ..Making your re
0fe0: 70 6f 73 69 74 6f 72 79 20 61 76 61 69 6c 61 62  pository availab
0ff0: 6c 65 20 6f 76 65 72 20 74 68 65 20 77 65 62 20  le over the web 
1000: 69 73 20 74 72 69 76 69 61 6c 20 74 6f 20 64 6f  is trivial to do
1010: 2e 20 57 65 0a 61 73 73 75 6d 65 20 79 6f 75 20  . We.assume you 
1020: 68 61 76 65 20 73 6f 6d 65 20 77 65 62 20 73 70  have some web sp
1030: 61 63 65 20 77 68 65 72 65 20 79 6f 75 20 63 61  ace where you ca
1040: 6e 20 73 74 6f 72 65 20 79 6f 75 72 20 66 6f 73  n store your fos
1050: 73 69 6c 20 66 69 6c 65 0a 61 6e 64 20 72 75 6e  sil file.and run
1060: 20 61 20 43 47 49 20 73 63 72 69 70 74 2e 20 49   a CGI script. I
1070: 66 20 6e 6f 74 2c 20 74 68 65 6e 20 74 68 69 73  f not, then this
1080: 20 6f 70 74 69 6f 6e 20 69 73 20 6e 6f 74 20 66   option is not f
1090: 6f 72 20 79 6f 75 2e 20 49 66 0a 79 6f 75 20 64  or you. If.you d
10a0: 6f 2c 20 74 68 65 6e 20 68 65 72 65 27 73 20 68  o, then here's h
10b0: 6f 77 2e 2e 2e 0a 0a 43 6f 70 79 20 63 6f 70 79  ow.....Copy copy
10c0: 20 74 68 65 20 66 6f 73 73 69 6c 20 72 65 70 6f   the fossil repo
10d0: 73 69 74 6f 72 79 20 66 69 6c 65 20 74 6f 20 79  sitory file to y
10e0: 6f 75 72 20 77 65 62 20 73 65 72 76 65 72 20 28  our web server (
10f0: 69 74 20 64 6f 65 73 6e 27 74 0a 6d 61 74 74 65  it doesn't.matte
1100: 72 20 77 68 65 72 65 2c 20 72 65 61 6c 6c 79 29  r where, really)
1110: 2e 0a 0a 49 6e 20 79 6f 75 72 20 3c 74 74 3e 63  ...In your <tt>c
1120: 67 69 2d 62 69 6e 3c 2f 74 74 3e 20 28 6f 72 20  gi-bin</tt> (or 
1130: 65 71 75 69 76 61 6c 65 6e 74 29 20 64 69 72 65  equivalent) dire
1140: 63 74 6f 72 79 2c 20 63 72 65 61 74 65 20 61 20  ctory, create a 
1150: 66 69 6c 65 0a 77 68 69 63 68 20 6c 6f 6f 6b 73  file.which looks
1160: 20 6c 69 6b 65 20 74 68 69 73 3a 0a 0a 3c 76 65   like this:..<ve
1170: 72 62 61 74 69 6d 3e 0a 23 21 2f 70 61 74 68 2f  rbatim>.#!/path/
1180: 74 6f 2f 66 6f 73 73 69 6c 0a 72 65 70 6f 73 69  to/fossil.reposi
1190: 74 6f 72 79 3a 20 2f 70 61 74 68 2f 74 6f 2f 6d  tory: /path/to/m
11a0: 79 5f 72 65 70 6f 2e 66 6f 73 73 69 6c 0a 3c 2f  y_repo.fossil.</
11b0: 76 65 72 62 61 74 69 6d 3e 0a 0a 4d 61 6b 65 20  verbatim>..Make 
11c0: 74 68 61 74 20 73 63 72 69 70 74 20 65 78 65 63  that script exec
11d0: 75 74 61 62 6c 65 2c 20 61 6e 64 20 79 6f 75 27  utable, and you'
11e0: 72 65 20 61 6c 6c 20 72 65 61 64 79 20 74 6f 20  re all ready to 
11f0: 67 6f 3a 0a 0a 3c 76 65 72 62 61 74 69 6d 3e 0a  go:..<verbatim>.
1200: 7e 2f 77 77 77 2f 63 67 69 2d 62 69 6e 3e 20 63  ~/www/cgi-bin> c
1210: 68 6d 6f 64 20 2b 78 20 6d 79 72 65 70 6f 2e 63  hmod +x myrepo.c
1220: 67 69 0a 3c 2f 76 65 72 62 61 74 69 6d 3e 0a 0a  gi.</verbatim>..
1230: 4e 6f 77 20 73 69 6d 70 6c 79 20 70 6f 69 6e 74  Now simply point
1240: 20 79 6f 75 72 20 62 72 6f 77 73 65 72 20 74 6f   your browser to
1250: 0a 3c 74 74 3e 68 74 74 70 3a 2f 2f 6d 79 2e 64  .<tt>http://my.d
1260: 6f 6d 61 69 6e 2f 63 67 69 2d 62 69 6e 2f 6d 79  omain/cgi-bin/my
1270: 72 65 70 6f 2e 63 67 69 3c 2f 74 74 3e 20 61 6e  repo.cgi</tt> an
1280: 64 20 79 6f 75 20 73 68 6f 75 6c 64 0a 62 65 20  d you should.be 
1290: 61 62 6c 65 20 74 6f 20 6d 61 6e 61 67 65 20 74  able to manage t
12a0: 68 65 20 72 65 70 6f 73 69 74 6f 72 79 20 66 72  he repository fr
12b0: 6f 6d 20 74 68 65 72 65 2e 0a 0a 54 6f 20 63 68  om there...To ch
12c0: 65 63 6b 20 6f 75 74 20 61 20 63 6f 70 79 20 6f  eck out a copy o
12d0: 66 20 79 6f 75 72 20 72 65 6d 6f 74 65 20 72 65  f your remote re
12e0: 70 6f 73 69 74 6f 72 79 2c 20 75 73 65 20 74 68  pository, use th
12f0: 65 0a 3c 65 6d 3e 63 6c 6f 6e 65 3c 2f 65 6d 3e  e.<em>clone</em>
1300: 20 63 6f 6d 6d 61 6e 64 3a 0a 0a 3c 76 65 72 62   command:..<verb
1310: 61 74 69 6d 3e 0a 73 74 65 70 68 61 6e 40 6c 75  atim>.stephan@lu
1320: 64 6f 3a 7e 2f 66 6f 73 73 69 6c 24 20 66 6f 73  do:~/fossil$ fos
1330: 73 69 6c 20 63 6c 6f 6e 65 20 5c 0a 20 20 68 74  sil clone \.  ht
1340: 74 70 3a 2f 2f 4d 79 41 63 63 6f 75 6e 74 4e 61  tp://MyAccountNa
1350: 6d 65 3a 4d 79 41 63 63 6f 75 6e 74 50 61 73 73  me:MyAccountPass
1360: 77 6f 72 64 40 6d 79 2e 64 6f 6d 61 69 6e 2f 63  word@my.domain/c
1370: 67 69 2d 62 69 6e 2f 6d 79 72 65 70 6f 2e 63 67  gi-bin/myrepo.cg
1380: 69 0a 3c 2f 76 65 72 62 61 74 69 6d 3e 0a 0a 4e  i.</verbatim>..N
1390: 6f 74 65 20 74 68 61 74 20 79 6f 75 20 73 68 6f  ote that you sho
13a0: 75 6c 64 20 70 61 73 73 20 79 6f 75 72 20 66 6f  uld pass your fo
13b0: 73 73 69 6c 20 6c 6f 67 69 6e 20 6e 61 6d 65 20  ssil login name 
13c0: 61 6e 64 20 70 61 73 73 77 6f 72 64 20 28 61 73  and password (as
13d0: 20 73 65 74 0a 76 69 61 20 6c 6f 63 61 6c 20 73   set.via local s
13e0: 65 72 76 65 72 20 6d 6f 64 65 29 20 64 75 72 69  erver mode) duri
13f0: 6e 67 20 74 68 65 20 63 6c 6f 6e 65 20 2d 20 74  ng the clone - t
1400: 68 61 74 20 65 6e 73 75 72 65 73 20 74 68 61 74  hat ensures that
1410: 20 66 6f 73 73 69 6c 0a 77 6f 6e 27 74 20 61 73   fossil.won't as
1420: 6b 20 79 6f 75 20 66 6f 72 20 69 74 20 6f 6e 20  k you for it on 
1430: 65 61 63 68 20 63 6f 6d 6d 69 74 21 0a 0a 41 20  each commit!..A 
1440: 63 6c 6f 6e 65 20 69 73 20 61 20 6c 6f 63 61 6c  clone is a local
1450: 20 63 6f 70 79 20 6f 66 20 61 20 72 65 6d 6f 74   copy of a remot
1460: 65 20 72 65 70 6f 73 69 74 6f 72 79 2c 20 61 6e  e repository, an
1470: 64 20 63 61 6e 20 62 65 20 6f 70 65 6e 65 64 20  d can be opened 
1480: 6a 75 73 74 0a 6c 69 6b 65 20 61 20 6c 6f 63 61  just.like a loca
1490: 6c 20 6f 6e 65 20 28 61 73 20 73 68 6f 77 6e 20  l one (as shown 
14a0: 61 62 6f 76 65 29 2e 20 49 74 20 69 73 20 74 72  above). It is tr
14b0: 65 61 74 65 64 20 69 64 65 6e 74 69 63 61 6c 6c  eated identicall
14c0: 79 20 74 6f 20 79 6f 75 72 0a 6c 6f 63 61 6c 20  y to your.local 
14d0: 72 65 70 6f 73 69 74 6f 72 79 2c 20 77 69 74 68  repository, with
14e0: 20 6f 6e 65 20 76 65 72 79 20 69 6d 70 6f 72 74   one very import
14f0: 61 6e 74 20 64 69 66 66 65 72 65 6e 63 65 2e 20  ant difference. 
1500: 20 57 68 65 6e 20 79 6f 75 20 63 6f 6d 6d 69 74   When you commit
1510: 0a 63 68 61 6e 67 65 73 20 74 6f 20 61 20 63 6c  .changes to a cl
1520: 6f 6e 65 64 20 72 65 6d 6f 74 65 20 72 65 70 6f  oned remote repo
1530: 73 69 74 6f 72 79 2c 20 74 68 65 79 20 77 69 6c  sitory, they wil
1540: 6c 20 62 65 20 70 75 73 68 65 64 20 62 61 63 6b  l be pushed back
1550: 20 74 6f 20 74 68 65 0a 72 65 6d 6f 74 65 20 72   to the.remote r
1560: 65 70 6f 73 69 74 6f 72 79 2e 20 49 66 20 79 6f  epository. If yo
1570: 75 20 68 61 76 65 20 3c 74 74 3e 61 75 74 6f 73  u have <tt>autos
1580: 79 6e 63 3c 2f 74 74 3e 20 6f 6e 20 74 68 65 6e  ync</tt> on then
1590: 20 74 68 69 73 20 73 79 6e 63 0a 68 61 70 70 65   this sync.happe
15a0: 6e 73 20 61 75 74 6f 6d 61 74 69 63 61 6c 6c 79  ns automatically
15b0: 2c 20 6f 74 68 65 72 77 69 73 65 20 79 6f 75 20  , otherwise you 
15c0: 77 69 6c 6c 20 6e 65 65 64 20 74 6f 20 75 73 65  will need to use
15d0: 20 74 68 65 0a 3c 65 6d 3e 70 75 6c 6c 3c 2f 65   the.<em>pull</e
15e0: 6d 3e 20 63 6f 6d 6d 61 6e 64 20 74 6f 20 67 65  m> command to ge
15f0: 74 20 72 65 6d 6f 74 65 20 63 68 61 6e 67 65 73  t remote changes
1600: 20 61 6e 64 20 74 68 65 20 3c 65 6d 3e 70 75 73   and the <em>pus
1610: 68 3c 2f 65 6d 3e 0a 63 6f 6d 6d 61 6e 64 20 74  h</em>.command t
1620: 6f 20 70 75 73 68 20 79 6f 75 72 20 6c 6f 63 61  o push your loca
1630: 6c 20 63 6f 6d 6d 69 74 73 20 74 6f 20 74 68 65  l commits to the
1640: 20 72 65 6d 6f 74 65 20 72 65 70 6f 73 69 74 6f   remote reposito
1650: 72 79 2e 20 59 6f 75 20 6d 75 73 74 0a 6f 66 20  ry. You must.of 
1660: 63 6f 75 72 73 65 20 68 61 76 65 20 61 75 74 68  course have auth
1670: 6f 72 69 7a 61 74 69 6f 6e 20 74 6f 20 63 6f 6d  orization to com
1680: 6d 69 74 20 63 68 61 6e 67 65 73 20 28 61 63 63  mit changes (acc
1690: 65 73 73 20 69 73 20 63 6f 6e 66 69 67 75 72 65  ess is configure
16a0: 64 0a 76 69 61 20 74 68 65 20 41 64 6d 69 6e 2f  d.via the Admin/
16b0: 55 73 65 72 73 20 70 61 67 65 20 6d 65 6e 74 69  Users page menti
16c0: 6f 6e 65 64 20 61 62 6f 76 65 29 2e 0a 0a 59 6f  oned above)...Yo
16d0: 75 20 6d 61 79 20 61 6c 77 61 79 73 20 75 73 65  u may always use
16e0: 20 74 68 65 20 3c 65 6d 3e 73 65 72 76 65 72 3c   the <em>server<
16f0: 2f 65 6d 3e 20 6f 72 20 3c 65 6d 3e 75 69 3c 2f  /em> or <em>ui</
1700: 65 6d 3e 20 63 6f 6d 6d 61 6e 64 73 20 74 6f 0a  em> commands to.
1710: 62 72 6f 77 73 65 20 61 20 63 6c 6f 6e 65 64 20  browse a cloned 
1720: 72 65 70 6f 73 69 74 6f 72 79 2e 20 59 6f 75 20  repository. You 
1730: 63 61 6e 20 65 76 65 6e 20 65 64 69 74 20 63 72  can even edit cr
1740: 65 61 74 65 20 6f 72 20 77 69 6b 69 20 65 6e 74  eate or wiki ent
1750: 72 69 65 73 2c 0a 65 74 63 2e 2c 20 61 6e 64 20  ries,.etc., and 
1760: 74 68 65 79 20 77 69 6c 6c 20 62 65 20 70 75 73  they will be pus
1770: 68 65 64 20 74 6f 20 74 68 65 20 72 65 6d 6f 74  hed to the remot
1780: 65 20 73 69 64 65 20 74 68 65 20 6e 65 78 74 20  e side the next 
1790: 74 69 6d 65 20 79 6f 75 0a 70 75 73 68 20 64 61  time you.push da
17a0: 74 61 20 74 6f 20 74 68 65 20 74 68 65 20 72 65  ta to the the re
17b0: 6d 6f 74 65 2e 0a                                mote..