Artifact ab22bff69f02338610b33e7392cb71481eeca8b9:
Wiki page
[Cookbook]
by
anonymous on
2009-04-20 14:07:46.
0000: 44 20 32 30 30 39 2d 30 34 2d 32 30 54 31 34 3a D 2009-04-20T14:
0010: 30 37 3a 34 36 0a 4c 20 43 6f 6f 6b 62 6f 6f 6b 07:46.L Cookbook
0020: 0a 50 20 35 31 66 30 39 64 37 65 36 38 32 34 37 .P 51f09d7e68247
0030: 35 37 34 30 34 32 32 62 65 63 38 39 38 31 30 64 5740422bec89810d
0040: 31 39 63 31 63 37 63 32 33 32 61 0a 55 20 61 6e 19c1c7c232a.U an
0050: 6f 6e 79 6d 6f 75 73 0a 57 20 31 38 39 35 36 0a onymous.W 18956.
0060: 3c 68 31 3e 46 6f 73 73 69 6c 20 43 6f 6f 6b 62 <h1>Fossil Cookb
0070: 6f 6f 6b 3c 2f 68 31 3e 0d 0a 54 68 65 20 3c 63 ook</h1>..The <c
0080: 69 74 65 3e 46 6f 73 73 69 6c 3c 2f 63 69 74 65 ite>Fossil</cite
0090: 3e 20 43 6f 6f 6b 62 6f 6f 6b 20 69 73 20 61 20 > Cookbook is a
00a0: 63 6f 6c 6c 65 63 74 69 6f 6e 20 6f 66 20 74 61 collection of ta
00b0: 73 6b 2d 6f 72 69 65 6e 74 65 64 20 69 6e 73 74 sk-oriented inst
00c0: 72 75 63 74 69 6f 6e 73 20 66 6f 72 20 69 6e 74 ructions for int
00d0: 65 72 6d 65 64 69 61 74 65 20 75 73 65 72 73 20 ermediate users
00e0: 77 68 6f 20 77 69 73 68 20 74 6f 20 64 6f 20 6d who wish to do m
00f0: 6f 72 65 20 74 68 61 6e 20 62 61 73 69 63 20 6f ore than basic o
0100: 70 65 72 61 74 69 6f 6e 73 20 77 69 74 68 20 74 perations with t
0110: 68 65 69 72 20 3c 63 69 74 65 3e 46 6f 73 73 69 heir <cite>Fossi
0120: 6c 3c 2f 63 69 74 65 3e 20 72 65 70 6f 73 69 74 l</cite> reposit
0130: 6f 72 69 65 73 2e 20 20 54 68 65 20 5b 54 75 74 ories. The [Tut
0140: 6f 72 69 61 6c 7c 74 75 74 6f 72 69 61 6c 5d 20 orial|tutorial]
0150: 69 73 20 61 20 6d 6f 72 65 20 73 75 69 74 61 62 is a more suitab
0160: 6c 65 20 70 6c 61 63 65 20 66 6f 72 20 6e 65 77 le place for new
0170: 63 6f 6d 65 72 73 20 74 72 79 69 6e 67 20 74 6f comers trying to
0180: 20 6c 65 61 72 6e 20 74 68 65 20 62 61 73 69 63 learn the basic
0190: 20 63 6f 6e 63 65 70 74 73 20 74 6f 20 67 6f 20 concepts to go
01a0: 66 69 72 73 74 20 62 65 66 6f 72 65 20 74 61 63 first before tac
01b0: 6b 6c 69 6e 67 20 74 68 65 73 65 20 72 65 63 69 kling these reci
01c0: 70 65 73 2e 0d 0a 0d 0a 3c 68 32 3e 49 6e 64 65 pes.....<h2>Inde
01d0: 78 3c 2f 68 32 3e 0d 0a 3c 75 6c 3e 0d 0a 20 20 x</h2>..<ul>..
01e0: 3c 6c 69 3e 20 53 65 72 76 65 72 20 72 65 63 69 <li> Server reci
01f0: 70 65 73 3a 0d 0a 20 20 20 20 3c 75 6c 3e 0d 0a pes:.. <ul>..
0200: 20 20 20 20 20 20 3c 6c 69 3e 20 20 3c 61 20 68 <li> <a h
0210: 72 65 66 3d 22 23 43 47 49 22 3e 55 73 69 6e 67 ref="#CGI">Using
0220: 20 3c 63 69 74 65 3e 46 6f 73 73 69 6c 3c 2f 63 <cite>Fossil</c
0230: 69 74 65 3e 27 73 20 42 75 69 6c 74 2d 49 6e 20 ite>'s Built-In
0240: 43 47 49 3c 2f 61 3e 0d 0a 20 20 20 20 3c 2f 75 CGI</a>.. </u
0250: 6c 3e 0d 0a 20 20 3c 6c 69 3e 20 3c 61 20 68 72 l>.. <li> <a hr
0260: 65 66 3d 22 23 65 6e 76 22 3e 55 73 69 6e 67 20 ef="#env">Using
0270: 45 6e 76 69 72 6f 6e 6d 65 6e 74 20 76 61 72 69 Environment vari
0280: 61 62 6c 65 73 3c 2f 61 3e 0d 0a 20 20 3c 6c 69 ables</a>.. <li
0290: 3e 20 3c 61 20 68 72 65 66 3d 22 23 63 73 73 22 > <a href="#css"
02a0: 3e 45 78 61 6d 70 6c 65 20 43 53 53 3c 2f 61 3e >Example CSS</a>
02b0: 0d 0a 20 20 3c 6c 69 3e 20 3c 61 20 68 72 65 66 .. <li> <a href
02c0: 3d 22 23 73 6f 75 72 63 65 2d 68 69 6c 69 67 68 ="#source-hiligh
02d0: 74 22 3e 53 6f 75 72 63 65 20 68 69 67 68 6c 69 t">Source highli
02e0: 67 68 74 69 6e 67 3c 2f 61 3e 0d 0a 3c 2f 75 6c ghting</a>..</ul
02f0: 3e 0d 0a 0d 0a 3c 68 32 3e 3c 61 20 6e 61 6d 65 >....<h2><a name
0300: 3d 22 43 47 49 22 3e 55 73 69 6e 67 20 3c 63 69 ="CGI">Using <ci
0310: 74 65 3e 46 6f 73 73 69 6c 3c 2f 63 69 74 65 3e te>Fossil</cite>
0320: 27 73 20 42 75 69 6c 74 2d 49 6e 20 43 47 49 3c 's Built-In CGI<
0330: 2f 61 3e 3c 2f 68 32 3e 0d 0a 3c 68 33 3e 4d 6f /a></h2>..<h3>Mo
0340: 74 69 76 61 74 69 6f 6e 3c 2f 68 33 3e 0d 0a 20 tivation</h3>..
0350: 20 2a 20 20 59 6f 75 20 77 61 6e 74 20 74 6f 20 * You want to
0360: 73 68 61 72 65 20 61 20 72 65 70 6f 73 69 74 6f share a reposito
0370: 72 79 20 74 68 72 6f 75 67 68 20 79 6f 75 72 20 ry through your
0380: 65 78 69 73 74 69 6e 67 20 77 65 62 20 69 6e 66 existing web inf
0390: 72 61 73 74 72 75 63 74 75 72 65 2e 0d 0a 20 20 rastructure...
03a0: 2a 20 20 59 6f 75 20 77 61 6e 74 20 74 6f 20 73 * You want to s
03b0: 68 61 72 65 20 6d 6f 72 65 20 74 68 61 6e 20 6f hare more than o
03c0: 6e 65 20 72 65 70 6f 73 69 74 6f 72 79 20 61 74 ne repository at
03d0: 20 74 68 65 20 73 61 6d 65 20 74 69 6d 65 2e 0d the same time..
03e0: 0a 0d 0a 3c 68 33 3e 50 72 6f 62 6c 65 6d 3c 2f ...<h3>Problem</
03f0: 68 33 3e 0d 0a 55 6e 6c 69 6b 65 20 73 6f 6d 65 h3>..Unlike some
0400: 20 6f 74 68 65 72 20 64 69 73 74 72 69 62 75 74 other distribut
0410: 65 64 20 53 43 4d 73 2c 20 3c 63 69 74 65 3e 46 ed SCMs, <cite>F
0420: 6f 73 73 69 6c 3c 2f 63 69 74 65 3e 20 63 61 6e ossil</cite> can
0430: 20 6f 6e 6c 79 20 63 6c 6f 6e 65 2c 20 70 75 73 only clone, pus
0440: 68 2c 20 70 75 6c 6c 20 61 6e 64 20 61 6e 64 20 h, pull and and
0450: 6f 74 68 65 72 77 69 73 65 20 69 6e 74 65 72 61 otherwise intera
0460: 63 74 20 74 68 72 6f 75 67 68 20 72 65 70 6f 73 ct through repos
0470: 69 74 6f 72 69 65 73 20 6f 76 65 72 20 48 54 54 itories over HTT
0480: 50 2e 20 20 54 68 69 73 20 63 61 6e 20 62 65 20 P. This can be
0490: 73 69 6d 70 6c 79 20 61 6e 64 20 65 61 73 69 6c simply and easil
04a0: 79 20 6d 61 6e 61 67 65 64 20 74 68 72 6f 75 67 y managed throug
04b0: 68 20 75 73 65 20 6f 66 20 74 68 65 20 3c 63 6f h use of the <co
04c0: 64 65 3e 66 6f 73 73 69 6c 20 73 65 72 76 65 72 de>fossil server
04d0: 3c 2f 63 6f 64 65 3e 20 61 6e 64 2f 6f 72 20 3c </code> and/or <
04e0: 63 6f 64 65 3e 66 6f 73 73 69 6c 20 75 69 3c 2f code>fossil ui</
04f0: 63 6f 64 65 3e 20 63 6f 6d 6d 61 6e 64 73 2c 20 code> commands,
0500: 6f 66 20 63 6f 75 72 73 65 2c 20 62 75 74 20 74 of course, but t
0510: 68 69 73 20 69 73 20 72 65 61 6c 6c 79 20 6f 6e his is really on
0520: 6c 79 20 61 64 65 71 75 61 74 65 20 66 6f 72 20 ly adequate for
0530: 61 64 2d 68 6f 63 20 72 65 70 6f 73 69 74 6f 72 ad-hoc repositor
0540: 79 20 73 68 61 72 69 6e 67 2e 20 20 43 6f 6e 73 y sharing. Cons
0550: 69 64 65 72 2c 20 66 6f 72 20 65 78 61 6d 70 6c ider, for exampl
0560: 65 2c 20 73 68 61 72 69 6e 67 20 74 65 6e 20 72 e, sharing ten r
0570: 65 70 6f 73 69 74 6f 72 69 65 73 2e 20 20 55 73 epositories. Us
0580: 69 6e 67 20 74 68 65 20 62 75 69 6c 74 2d 69 6e ing the built-in
0590: 20 73 65 72 76 65 72 20 77 6f 75 6c 64 20 72 65 server would re
05a0: 71 75 69 72 65 20 79 6f 75 20 74 6f 20 6f 70 65 quire you to ope
05b0: 6e 20 74 65 6e 20 70 6f 72 74 73 20 69 6e 20 79 n ten ports in y
05c0: 6f 75 72 20 66 69 72 65 77 61 6c 6c 20 74 6f 20 our firewall to
05d0: 70 65 72 6d 69 74 20 61 63 63 65 73 73 2e 20 20 permit access.
05e0: 41 6e 79 20 73 65 72 69 6f 75 73 20 73 68 61 72 Any serious shar
05f0: 69 6e 67 20 77 69 6c 6c 20 72 65 71 75 69 72 65 ing will require
0600: 20 73 6f 6d 65 74 68 69 6e 67 20 6d 6f 72 65 20 something more
0610: 72 6f 62 75 73 74 20 61 6e 64 20 70 65 72 6d 61 robust and perma
0620: 6e 65 6e 74 2e 0d 0a 0d 0a 3c 68 33 3e 53 6f 6c nent.....<h3>Sol
0630: 75 74 69 6f 6e 3c 2f 68 33 3e 0d 0a 3c 63 69 74 ution</h3>..<cit
0640: 65 3e 46 6f 73 73 69 6c 3c 2f 63 69 74 65 3e 20 e>Fossil</cite>
0650: 73 75 70 70 6f 72 74 73 20 74 68 72 65 65 20 64 supports three d
0660: 69 66 66 65 72 65 6e 74 20 77 61 79 73 20 74 6f ifferent ways to
0670: 20 73 68 61 72 65 20 72 65 70 6f 73 69 74 6f 72 share repositor
0680: 69 65 73 2e 20 20 46 6f 72 20 61 64 2d 68 6f 63 ies. For ad-hoc
0690: 20 73 68 61 72 69 6e 67 20 3c 63 6f 64 65 3e 66 sharing <code>f
06a0: 6f 73 73 69 6c 20 73 65 72 76 65 72 2f 75 69 3c ossil server/ui<
06b0: 2f 63 6f 64 65 3e 20 69 73 20 6d 6f 72 65 20 74 /code> is more t
06c0: 68 61 6e 20 61 64 65 71 75 61 74 65 2e 20 20 46 han adequate. F
06d0: 6f 72 20 6d 6f 72 65 20 72 6f 62 75 73 74 20 73 or more robust s
06e0: 6f 6c 75 74 69 6f 6e 73 2c 20 68 6f 77 65 76 65 olutions, howeve
06f0: 72 2c 20 74 68 65 20 75 73 65 20 6f 66 20 3c 63 r, the use of <c
0700: 69 74 65 3e 28 78 29 69 6e 65 74 64 3c 2f 63 69 ite>(x)inetd</ci
0710: 74 65 3e 20 6f 72 20 43 47 49 20 73 75 70 70 6f te> or CGI suppo
0720: 72 74 20 69 73 20 69 6e 64 69 63 61 74 65 64 2e rt is indicated.
0730: 0d 0a 0d 0a 53 65 74 74 69 6e 67 20 75 70 20 66 ....Setting up f
0740: 6f 73 73 69 6c 20 66 6f 72 20 43 47 49 20 73 75 ossil for CGI su
0750: 70 70 6f 72 74 20 69 73 20 73 69 6d 70 6c 65 2e pport is simple.
0760: 20 20 28 53 65 74 74 69 6e 67 20 75 70 20 79 6f (Setting up yo
0770: 75 72 20 77 65 62 20 73 65 72 76 65 72 20 66 6f ur web server fo
0780: 72 20 43 47 49 20 73 75 70 70 6f 72 74 20 6d 61 r CGI support ma
0790: 79 20 6f 72 20 6d 61 79 20 6e 6f 74 20 62 65 20 y or may not be
07a0: 73 69 6d 70 6c 65 2c 20 62 75 74 20 69 74 20 69 simple, but it i
07b0: 73 20 6f 75 74 20 6f 66 20 73 63 6f 70 65 20 6f s out of scope o
07c0: 66 20 74 68 69 73 20 72 65 63 69 70 65 2e 20 20 f this recipe.
07d0: 43 6f 6e 73 75 6c 74 20 79 6f 75 72 20 77 65 62 Consult your web
07e0: 20 73 65 72 76 65 72 2f 73 65 72 76 69 63 65 20 server/service
07f0: 70 72 6f 76 69 64 65 72 27 73 20 64 6f 63 75 6d provider's docum
0800: 65 6e 74 61 74 69 6f 6e 20 66 6f 72 20 74 68 69 entation for thi
0810: 73 2e 29 0d 0a 0d 0a 3c 68 34 3e 55 4e 49 58 3c s.)....<h4>UNIX<
0820: 2f 68 34 3e 0d 0a 20 20 31 2e 20 20 46 69 6e 64 /h4>.. 1. Find
0830: 20 79 6f 75 72 20 43 47 49 20 73 63 72 69 70 74 your CGI script
0840: 73 20 64 69 72 65 63 74 6f 72 79 20 28 69 66 20 s directory (if
0850: 61 70 70 6c 69 63 61 62 6c 65 29 2e 20 20 54 68 applicable). Th
0860: 69 73 20 69 73 20 63 6f 6d 6d 6f 6e 6c 79 20 73 is is commonly s
0870: 6f 6d 65 74 68 69 6e 67 20 6c 69 6b 65 20 3c 62 omething like <b
0880: 61 73 65 3e 2f 63 67 69 2d 62 69 6e 2f 2c 20 62 ase>/cgi-bin/, b
0890: 75 74 20 64 6f 65 73 20 6e 6f 74 20 68 61 76 65 ut does not have
08a0: 20 74 6f 20 62 65 2e 0d 0a 20 20 32 2e 20 20 49 to be... 2. I
08b0: 6e 73 69 64 65 20 74 68 61 74 20 64 69 72 65 63 nside that direc
08c0: 74 6f 72 79 20 62 75 69 6c 64 20 61 20 73 63 72 tory build a scr
08d0: 69 70 74 20 66 69 6c 65 20 77 68 69 63 68 20 6c ipt file which l
08e0: 6f 6f 6b 73 20 6c 69 6b 65 20 74 68 69 73 3a 3c ooks like this:<
08f0: 62 72 3e 3c 63 6f 64 65 3e 3c 70 72 65 3e 20 20 br><code><pre>
0900: 23 21 20 2f 75 73 72 2f 62 69 6e 2f 65 6e 76 20 #! /usr/bin/env
0910: 66 6f 73 73 69 6c 3c 62 72 3e 20 20 72 65 70 6f fossil<br> repo
0920: 73 69 74 6f 72 79 3a 20 2f 66 75 6c 6c 2f 70 61 sitory: /full/pa
0930: 74 68 2f 74 6f 2f 72 65 70 6f 73 69 74 6f 72 79 th/to/repository
0940: 2f 66 69 6c 65 2e 66 73 6c 3c 2f 70 72 65 3e 3c /file.fsl</pre><
0950: 2f 63 6f 64 65 3e 0d 0a 20 20 33 2e 20 20 45 6e /code>.. 3. En
0960: 73 75 72 65 20 74 68 61 74 20 74 68 65 20 73 63 sure that the sc
0970: 72 69 70 74 20 66 69 6c 65 20 73 6f 20 67 65 6e ript file so gen
0980: 65 72 61 74 65 64 20 69 73 20 73 65 74 20 65 78 erated is set ex
0990: 65 63 75 74 61 62 6c 65 20 66 6f 72 20 74 68 65 ecutable for the
09a0: 20 43 47 49 20 75 73 65 72 20 61 63 63 6f 75 6e CGI user accoun
09b0: 74 2e 0d 0a 20 20 34 2e 20 20 45 6e 73 75 72 65 t... 4. Ensure
09c0: 20 74 68 61 74 20 65 76 65 72 79 20 64 69 72 65 that every dire
09d0: 63 74 6f 72 79 20 69 6e 20 74 68 65 20 70 61 74 ctory in the pat
09e0: 68 20 6c 65 61 64 69 6e 67 20 74 6f 20 74 68 65 h leading to the
09f0: 20 72 65 70 6f 73 69 74 6f 72 79 20 69 73 20 20 repository is
0a00: 62 72 6f 77 73 65 61 62 6c 65 20 28 63 68 6d 6f browseable (chmo
0a10: 64 20 2b 78 29 20 74 6f 20 74 68 65 20 43 47 49 d +x) to the CGI
0a20: 20 75 73 65 72 20 61 63 63 6f 75 6e 74 2e 0d 0a user account...
0a30: 20 20 35 2e 20 20 45 6e 73 75 72 65 20 74 68 61 5. Ensure tha
0a40: 74 20 74 68 65 20 72 65 70 6f 73 69 74 6f 72 79 t the repository
0a50: 20 66 69 6c 65 20 69 73 20 72 65 61 64 61 62 6c file is readabl
0a60: 65 20 3c 65 6d 3e 61 6e 64 3c 2f 65 6d 3e 20 77 e <em>and</em> w
0a70: 72 69 74 61 62 6c 65 20 74 6f 20 74 68 65 20 43 ritable to the C
0a80: 47 49 20 75 73 65 72 20 61 63 63 6f 75 6e 74 2e GI user account.
0a90: 0d 0a 0d 0a 54 68 65 20 66 6f 6c 6c 6f 77 69 6e ....The followin
0aa0: 67 20 3c 63 69 74 65 3e 62 61 73 68 3c 2f 63 69 g <cite>bash</ci
0ab0: 74 65 3e 20 73 63 72 69 70 74 20 63 61 6e 20 62 te> script can b
0ac0: 65 20 72 75 6e 20 66 72 6f 6d 20 77 69 74 68 69 e run from withi
0ad0: 6e 20 74 68 65 20 64 69 72 65 63 74 6f 72 79 20 n the directory
0ae0: 63 6f 6e 74 61 69 6e 69 6e 67 20 74 68 65 20 3c containing the <
0af0: 63 69 74 65 3e 46 6f 73 73 69 6c 3c 2f 63 69 74 cite>Fossil</cit
0b00: 65 3e 20 72 65 70 6f 73 69 74 6f 72 69 65 73 20 e> repositories
0b10: 74 6f 20 62 65 20 73 68 61 72 65 64 20 28 61 6e to be shared (an
0b20: 64 2c 20 6f 66 20 63 6f 75 72 73 65 2c 20 61 6c d, of course, al
0b30: 74 65 72 65 64 20 66 6f 72 20 79 6f 75 72 20 73 tered for your s
0b40: 65 74 75 70 29 20 74 6f 20 73 65 74 20 73 6f 6d etup) to set som
0b50: 65 20 6f 66 20 74 68 65 20 63 6f 6e 73 74 72 61 e of the constra
0b60: 69 6e 74 73 20 61 62 6f 76 65 20 75 70 20 61 75 ints above up au
0b70: 74 6f 6d 61 74 69 63 61 6c 6c 79 3a 0d 0a 0d 0a tomatically:....
0b80: 3c 6e 6f 77 69 6b 69 3e 3c 66 6f 6e 74 20 66 61 <nowiki><font fa
0b90: 63 65 3d 22 6d 6f 6e 6f 73 70 61 63 65 22 3e 0d ce="monospace">.
0ba0: 0a 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 .<font color="#a
0bb0: 35 32 61 32 61 22 3e 26 6e 62 73 70 3b 31 20 3c 52a2a"> 1 <
0bc0: 2f 66 6f 6e 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f /font><font colo
0bd0: 72 3d 22 23 30 30 30 30 66 66 22 3e 23 21 20 2f r="#0000ff">#! /
0be0: 75 73 72 2f 62 69 6e 2f 65 6e 76 20 62 61 73 68 usr/bin/env bash
0bf0: 3c 2f 66 6f 6e 74 3e 3c 62 72 3e 0d 0a 3c 66 6f </font><br>..<fo
0c00: 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 nt color="#a52a2
0c10: 61 22 3e 26 6e 62 73 70 3b 32 20 3c 2f 66 6f 6e a"> 2 </fon
0c20: 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 t><font color="#
0c30: 30 30 38 62 38 62 22 3e 43 47 49 5f 52 4f 4f 54 008b8b">CGI_ROOT
0c40: 3c 2f 66 6f 6e 74 3e 3d 2f 75 73 72 2f 6c 69 62 </font>=/usr/lib
0c50: 2f 66 6f 73 73 69 6c 3c 62 72 3e 0d 0a 3c 66 6f /fossil<br>..<fo
0c60: 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 nt color="#a52a2
0c70: 61 22 3e 26 6e 62 73 70 3b 33 20 3c 2f 66 6f 6e a"> 3 </fon
0c80: 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 t><font color="#
0c90: 30 30 38 62 38 62 22 3e 52 45 50 4f 53 49 54 4f 008b8b">REPOSITO
0ca0: 52 59 5f 4f 57 4e 45 52 3c 2f 66 6f 6e 74 3e 3d RY_OWNER</font>=
0cb0: 6d 69 63 68 61 65 6c 3c 62 72 3e 0d 0a 3c 66 6f michael<br>..<fo
0cc0: 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 nt color="#a52a2
0cd0: 61 22 3e 26 6e 62 73 70 3b 34 20 3c 2f 66 6f 6e a"> 4 </fon
0ce0: 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 t><font color="#
0cf0: 30 30 38 62 38 62 22 3e 43 47 49 5f 47 52 4f 55 008b8b">CGI_GROU
0d00: 50 3c 2f 66 6f 6e 74 3e 3d 77 77 77 2d 64 61 74 P</font>=www-dat
0d10: 61 3c 62 72 3e 0d 0a 3c 66 6f 6e 74 20 63 6f 6c a<br>..<font col
0d20: 6f 72 3d 22 23 61 35 32 61 32 61 22 3e 26 6e 62 or="#a52a2a">&nb
0d30: 73 70 3b 35 20 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e sp;5 </font><fon
0d40: 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 61 t color="#a52a2a
0d50: 22 3e 3c 62 3e 69 66 3c 2f 62 3e 3c 2f 66 6f 6e "><b>if</b></fon
0d60: 74 3e 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 6f t> <font co
0d70: 6c 6f 72 3d 22 23 61 35 32 61 32 61 22 3e 3c 62 lor="#a52a2a"><b
0d80: 3e 5b 3c 2f 62 3e 3c 2f 66 6f 6e 74 3e 26 6e 62 >[</b></font>&nb
0d90: 73 70 3b 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 sp;<font color="
0da0: 23 36 61 35 61 63 64 22 3e 60 77 68 6f 61 6d 69 #6a5acd">`whoami
0db0: 60 3c 2f 66 6f 6e 74 3e 26 6e 62 73 70 3b 3c 66 `</font> <f
0dc0: 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 ont color="#a52a
0dd0: 32 61 22 3e 3c 62 3e 3d 3c 2f 62 3e 3c 2f 66 6f 2a"><b>=</b></fo
0de0: 6e 74 3e 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 nt> <font c
0df0: 6f 6c 6f 72 3d 22 23 66 66 30 30 66 66 22 3e 27 olor="#ff00ff">'
0e00: 72 6f 6f 74 27 3c 2f 66 6f 6e 74 3e 26 6e 62 73 root'</font>&nbs
0e10: 70 3b 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 p;<font color="#
0e20: 61 35 32 61 32 61 22 3e 3c 62 3e 5d 3c 2f 62 3e a52a2a"><b>]</b>
0e30: 3c 2f 66 6f 6e 74 3e 3c 62 72 3e 0d 0a 3c 66 6f </font><br>..<fo
0e40: 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 nt color="#a52a2
0e50: 61 22 3e 26 6e 62 73 70 3b 36 20 3c 2f 66 6f 6e a"> 6 </fon
0e60: 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 t><font color="#
0e70: 61 35 32 61 32 61 22 3e 3c 62 3e 74 68 65 6e 3c a52a2a"><b>then<
0e80: 2f 62 3e 3c 2f 66 6f 6e 74 3e 3c 62 72 3e 0d 0a /b></font><br>..
0e90: 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 <font color="#a5
0ea0: 32 61 32 61 22 3e 26 6e 62 73 70 3b 37 20 3c 2f 2a2a"> 7 </
0eb0: 66 6f 6e 74 3e 26 6e 62 73 70 3b 26 6e 62 73 70 font>  
0ec0: 3b 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 ;<font color="#a
0ed0: 35 32 61 32 61 22 3e 3c 62 3e 66 6f 72 3c 2f 62 52a2a"><b>for</b
0ee0: 3e 3c 2f 66 6f 6e 74 3e 26 6e 62 73 70 3b 72 65 ></font> re
0ef0: 70 6f 73 69 74 6f 72 79 20 3c 66 6f 6e 74 20 63 pository <font c
0f00: 6f 6c 6f 72 3d 22 23 61 35 32 61 32 61 22 3e 3c olor="#a52a2a"><
0f10: 62 3e 69 6e 3c 2f 62 3e 3c 2f 66 6f 6e 74 3e 26 b>in</b></font>&
0f20: 6e 62 73 70 3b 2a 2e 66 73 6c 3c 62 72 3e 0d 0a nbsp;*.fsl<br>..
0f30: 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 <font color="#a5
0f40: 32 61 32 61 22 3e 26 6e 62 73 70 3b 38 20 3c 2f 2a2a"> 8 </
0f50: 66 6f 6e 74 3e 26 6e 62 73 70 3b 26 6e 62 73 70 font>  
0f60: 3b 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 ;<font color="#a
0f70: 35 32 61 32 61 22 3e 3c 62 3e 64 6f 3c 2f 62 3e 52a2a"><b>do</b>
0f80: 3c 2f 66 6f 6e 74 3e 3c 62 72 3e 0d 0a 3c 66 6f </font><br>..<fo
0f90: 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 nt color="#a52a2
0fa0: 61 22 3e 26 6e 62 73 70 3b 39 20 3c 2f 66 6f 6e a"> 9 </fon
0fb0: 74 3e 26 6e 62 73 70 3b 26 6e 62 73 70 3b 26 6e t> &n
0fc0: 62 73 70 3b 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 bsp; <font
0fd0: 63 6f 6c 6f 72 3d 22 23 30 30 38 62 38 62 22 3e color="#008b8b">
0fe0: 53 4f 55 52 43 45 3c 2f 66 6f 6e 74 3e 3d 3c 66 SOURCE</font>=<f
0ff0: 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 36 61 35 61 ont color="#6a5a
1000: 63 64 22 3e 60 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e cd">`</font><fon
1010: 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 61 t color="#a52a2a
1020: 22 3e 3c 62 3e 70 77 64 3c 2f 62 3e 3c 2f 66 6f "><b>pwd</b></fo
1030: 6e 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 nt><font color="
1040: 23 36 61 35 61 63 64 22 3e 60 3c 2f 66 6f 6e 74 #6a5acd">`</font
1050: 3e 2f 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 >/<font color="#
1060: 61 30 32 30 66 30 22 3e 24 72 65 70 6f 73 69 74 a020f0">$reposit
1070: 6f 72 79 3c 2f 66 6f 6e 74 3e 3c 62 72 3e 0d 0a ory</font><br>..
1080: 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 <font color="#a5
1090: 32 61 32 61 22 3e 31 30 20 3c 2f 66 6f 6e 74 3e 2a2a">10 </font>
10a0: 26 6e 62 73 70 3b 26 6e 62 73 70 3b 26 6e 62 73 &nbs
10b0: 70 3b 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 6f p; <font co
10c0: 6c 6f 72 3d 22 23 30 30 38 62 38 62 22 3e 44 45 lor="#008b8b">DE
10d0: 53 54 49 4e 41 54 49 4f 4e 3c 2f 66 6f 6e 74 3e STINATION</font>
10e0: 3d 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 =<font color="#a
10f0: 30 32 30 66 30 22 3e 24 43 47 49 5f 52 4f 4f 54 020f0">$CGI_ROOT
1100: 3c 2f 66 6f 6e 74 3e 2f 3c 66 6f 6e 74 20 63 6f </font>/<font co
1110: 6c 6f 72 3d 22 23 61 30 32 30 66 30 22 3e 24 7b lor="#a020f0">${
1120: 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e 74 20 63 6f 6c </font><font col
1130: 6f 72 3d 22 23 61 30 32 30 66 30 22 3e 72 65 70 or="#a020f0">rep
1140: 6f 73 69 74 6f 72 79 3c 2f 66 6f 6e 74 3e 3c 66 ository</font><f
1150: 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 ont color="#a52a
1160: 32 61 22 3e 3c 62 3e 25 3c 2f 62 3e 3c 2f 66 6f 2a"><b>%</b></fo
1170: 6e 74 3e 2e 66 73 6c 3c 66 6f 6e 74 20 63 6f 6c nt>.fsl<font col
1180: 6f 72 3d 22 23 61 30 32 30 66 30 22 3e 7d 3c 2f or="#a020f0">}</
1190: 66 6f 6e 74 3e 3c 62 72 3e 0d 0a 3c 66 6f 6e 74 font><br>..<font
11a0: 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 61 22 color="#a52a2a"
11b0: 3e 31 31 20 3c 2f 66 6f 6e 74 3e 26 6e 62 73 70 >11 </font> 
11c0: 3b 26 6e 62 73 70 3b 26 6e 62 73 70 3b 26 6e 62 ; &nb
11d0: 73 70 3b 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 sp;<font color="
11e0: 23 61 35 32 61 32 61 22 3e 3c 62 3e 65 63 68 6f #a52a2a"><b>echo
11f0: 3c 2f 62 3e 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e 74 </b></font><font
1200: 20 63 6f 6c 6f 72 3d 22 23 66 66 30 30 66 66 22 color="#ff00ff"
1210: 3e 26 6e 62 73 70 3b 3c 2f 66 6f 6e 74 3e 3c 66 > </font><f
1220: 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 ont color="#a52a
1230: 32 61 22 3e 3c 62 3e 26 71 75 6f 74 3b 3c 2f 62 2a"><b>"</b
1240: 3e 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e 74 20 63 6f ></font><font co
1250: 6c 6f 72 3d 22 23 66 66 30 30 66 66 22 3e 23 21 lor="#ff00ff">#!
1260: 20 2f 75 73 72 2f 62 69 6e 2f 65 6e 76 20 66 6f /usr/bin/env fo
1270: 73 73 69 6c 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e 74 ssil</font><font
1280: 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 61 22 color="#a52a2a"
1290: 3e 3c 62 3e 26 71 75 6f 74 3b 3c 2f 62 3e 3c 2f ><b>"</b></
12a0: 66 6f 6e 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f 72 font><font color
12b0: 3d 22 23 66 66 30 30 66 66 22 3e 26 6e 62 73 70 ="#ff00ff"> 
12c0: 3b 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e 74 20 63 6f ;</font><font co
12d0: 6c 6f 72 3d 22 23 61 35 32 61 32 61 22 3e 3c 62 lor="#a52a2a"><b
12e0: 3e 26 67 74 3b 3c 2f 62 3e 3c 2f 66 6f 6e 74 3e >></b></font>
12f0: 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 6f 6c 6f <font colo
1300: 72 3d 22 23 61 30 32 30 66 30 22 3e 24 44 45 53 r="#a020f0">$DES
1310: 54 49 4e 41 54 49 4f 4e 3c 2f 66 6f 6e 74 3e 3c TINATION</font><
1320: 62 72 3e 0d 0a 3c 66 6f 6e 74 20 63 6f 6c 6f 72 br>..<font color
1330: 3d 22 23 61 35 32 61 32 61 22 3e 31 32 20 3c 2f ="#a52a2a">12 </
1340: 66 6f 6e 74 3e 26 6e 62 73 70 3b 26 6e 62 73 70 font>  
1350: 3b 26 6e 62 73 70 3b 26 6e 62 73 70 3b 3c 66 6f ; <fo
1360: 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 nt color="#a52a2
1370: 61 22 3e 3c 62 3e 65 63 68 6f 3c 2f 62 3e 3c 2f a"><b>echo</b></
1380: 66 6f 6e 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f 72 font><font color
1390: 3d 22 23 66 66 30 30 66 66 22 3e 26 6e 62 73 70 ="#ff00ff"> 
13a0: 3b 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e 74 20 63 6f ;</font><font co
13b0: 6c 6f 72 3d 22 23 61 35 32 61 32 61 22 3e 3c 62 lor="#a52a2a"><b
13c0: 3e 26 71 75 6f 74 3b 3c 2f 62 3e 3c 2f 66 6f 6e >"</b></fon
13d0: 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 t><font color="#
13e0: 66 66 30 30 66 66 22 3e 72 65 70 6f 73 69 74 6f ff00ff">reposito
13f0: 72 79 3a 20 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e 74 ry: </font><font
1400: 20 63 6f 6c 6f 72 3d 22 23 61 30 32 30 66 30 22 color="#a020f0"
1410: 3e 24 53 4f 55 52 43 45 3c 2f 66 6f 6e 74 3e 3c >$SOURCE</font><
1420: 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 font color="#a52
1430: 61 32 61 22 3e 3c 62 3e 26 71 75 6f 74 3b 3c 2f a2a"><b>"</
1440: 62 3e 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e 74 20 63 b></font><font c
1450: 6f 6c 6f 72 3d 22 23 66 66 30 30 66 66 22 3e 26 olor="#ff00ff">&
1460: 6e 62 73 70 3b 3c 2f 66 6f 6e 74 3e 3c 66 6f 6e nbsp;</font><fon
1470: 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 61 t color="#a52a2a
1480: 22 3e 3c 62 3e 26 67 74 3b 26 67 74 3b 3c 2f 62 "><b>>></b
1490: 3e 3c 2f 66 6f 6e 74 3e 26 6e 62 73 70 3b 3c 66 ></font> <f
14a0: 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 30 32 30 ont color="#a020
14b0: 66 30 22 3e 24 44 45 53 54 49 4e 41 54 49 4f 4e f0">$DESTINATION
14c0: 3c 2f 66 6f 6e 74 3e 3c 62 72 3e 0d 0a 3c 66 6f </font><br>..<fo
14d0: 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 nt color="#a52a2
14e0: 61 22 3e 31 33 20 3c 2f 66 6f 6e 74 3e 26 6e 62 a">13 </font>&nb
14f0: 73 70 3b 26 6e 62 73 70 3b 26 6e 62 73 70 3b 26 sp; &
1500: 6e 62 73 70 3b 63 68 6f 77 6e 20 3c 66 6f 6e 74 nbsp;chown <font
1510: 20 63 6f 6c 6f 72 3d 22 23 61 30 32 30 66 30 22 color="#a020f0"
1520: 3e 24 52 45 50 4f 53 49 54 4f 52 59 5f 4f 57 4e >$REPOSITORY_OWN
1530: 45 52 3c 2f 66 6f 6e 74 3e 3a 3c 66 6f 6e 74 20 ER</font>:<font
1540: 63 6f 6c 6f 72 3d 22 23 61 30 32 30 66 30 22 3e color="#a020f0">
1550: 24 43 47 49 5f 47 52 4f 55 50 3c 2f 66 6f 6e 74 $CGI_GROUP</font
1560: 3e 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 6f 6c > <font col
1570: 6f 72 3d 22 23 61 30 32 30 66 30 22 3e 24 53 4f or="#a020f0">$SO
1580: 55 52 43 45 3c 2f 66 6f 6e 74 3e 3c 62 72 3e 0d URCE</font><br>.
1590: 0a 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 .<font color="#a
15a0: 35 32 61 32 61 22 3e 31 34 20 3c 2f 66 6f 6e 74 52a2a">14 </font
15b0: 3e 26 6e 62 73 70 3b 26 6e 62 73 70 3b 26 6e 62 > &nb
15c0: 73 70 3b 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 sp; <font c
15d0: 6f 6c 6f 72 3d 22 23 61 35 32 61 32 61 22 3e 3c olor="#a52a2a"><
15e0: 62 3e 63 68 6d 6f 64 3c 2f 62 3e 3c 2f 66 6f 6e b>chmod</b></fon
15f0: 74 3e 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 6f t> <font co
1600: 6c 6f 72 3d 22 23 66 66 30 30 66 66 22 3e 36 36 lor="#ff00ff">66
1610: 34 3c 2f 66 6f 6e 74 3e 26 6e 62 73 70 3b 3c 66 4</font> <f
1620: 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 30 32 30 ont color="#a020
1630: 66 30 22 3e 24 53 4f 55 52 43 45 3c 2f 66 6f 6e f0">$SOURCE</fon
1640: 74 3e 3c 62 72 3e 0d 0a 3c 66 6f 6e 74 20 63 6f t><br>..<font co
1650: 6c 6f 72 3d 22 23 61 35 32 61 32 61 22 3e 31 35 lor="#a52a2a">15
1660: 20 3c 2f 66 6f 6e 74 3e 26 6e 62 73 70 3b 26 6e </font> &n
1670: 62 73 70 3b 26 6e 62 73 70 3b 26 6e 62 73 70 3b bsp;
1680: 63 68 6f 77 6e 20 72 6f 6f 74 3a 72 6f 6f 74 20 chown root:root
1690: 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 30 <font color="#a0
16a0: 32 30 66 30 22 3e 24 44 45 53 54 49 4e 41 54 49 20f0">$DESTINATI
16b0: 4f 4e 3c 2f 66 6f 6e 74 3e 3c 62 72 3e 0d 0a 3c ON</font><br>..<
16c0: 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 font color="#a52
16d0: 61 32 61 22 3e 31 36 20 3c 2f 66 6f 6e 74 3e 26 a2a">16 </font>&
16e0: 6e 62 73 70 3b 26 6e 62 73 70 3b 26 6e 62 73 70 nbsp;  
16f0: 3b 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 6f 6c ; <font col
1700: 6f 72 3d 22 23 61 35 32 61 32 61 22 3e 3c 62 3e or="#a52a2a"><b>
1710: 63 68 6d 6f 64 3c 2f 62 3e 3c 2f 66 6f 6e 74 3e chmod</b></font>
1720: 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 6f 6c 6f <font colo
1730: 72 3d 22 23 66 66 30 30 66 66 22 3e 37 35 35 3c r="#ff00ff">755<
1740: 2f 66 6f 6e 74 3e 26 6e 62 73 70 3b 3c 66 6f 6e /font> <fon
1750: 74 20 63 6f 6c 6f 72 3d 22 23 61 30 32 30 66 30 t color="#a020f0
1760: 22 3e 24 44 45 53 54 49 4e 41 54 49 4f 4e 3c 2f ">$DESTINATION</
1770: 66 6f 6e 74 3e 3c 62 72 3e 0d 0a 3c 66 6f 6e 74 font><br>..<font
1780: 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 32 61 22 color="#a52a2a"
1790: 3e 31 37 20 3c 2f 66 6f 6e 74 3e 26 6e 62 73 70 >17 </font> 
17a0: 3b 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 6f 6c ; <font col
17b0: 6f 72 3d 22 23 61 35 32 61 32 61 22 3e 3c 62 3e or="#a52a2a"><b>
17c0: 64 6f 6e 65 3c 2f 62 3e 3c 2f 66 6f 6e 74 3e 3c done</b></font><
17d0: 62 72 3e 0d 0a 3c 66 6f 6e 74 20 63 6f 6c 6f 72 br>..<font color
17e0: 3d 22 23 61 35 32 61 32 61 22 3e 31 38 20 3c 2f ="#a52a2a">18 </
17f0: 66 6f 6e 74 3e 3c 66 6f 6e 74 20 63 6f 6c 6f 72 font><font color
1800: 3d 22 23 61 35 32 61 32 61 22 3e 3c 62 3e 65 6c ="#a52a2a"><b>el
1810: 73 65 3c 2f 62 3e 3c 2f 66 6f 6e 74 3e 3c 62 72 se</b></font><br
1820: 3e 0d 0a 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d 22 >..<font color="
1830: 23 61 35 32 61 32 61 22 3e 31 39 20 3c 2f 66 6f #a52a2a">19 </fo
1840: 6e 74 3e 26 6e 62 73 70 3b 26 6e 62 73 70 3b 73 nt> s
1850: 75 64 6f 20 3c 66 6f 6e 74 20 63 6f 6c 6f 72 3d udo <font color=
1860: 22 23 61 30 32 30 66 30 22 3e 24 30 3c 2f 66 6f "#a020f0">$0</fo
1870: 6e 74 3e 26 6e 62 73 70 3b 3c 66 6f 6e 74 20 63 nt> <font c
1880: 6f 6c 6f 72 3d 22 23 61 30 32 30 66 30 22 3e 24 olor="#a020f0">$
1890: 2a 3c 2f 66 6f 6e 74 3e 3c 62 72 3e 0d 0a 3c 66 *</font><br>..<f
18a0: 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 ont color="#a52a
18b0: 32 61 22 3e 32 30 20 3c 2f 66 6f 6e 74 3e 3c 66 2a">20 </font><f
18c0: 6f 6e 74 20 63 6f 6c 6f 72 3d 22 23 61 35 32 61 ont color="#a52a
18d0: 32 61 22 3e 3c 62 3e 66 69 3c 2f 62 3e 3c 2f 66 2a"><b>fi</b></f
18e0: 6f 6e 74 3e 3c 62 72 3e 0d 0a 3c 2f 66 6f 6e 74 ont><br>..</font
18f0: 3e 3c 2f 6e 6f 77 69 6b 69 3e 0d 0a 0d 0a 54 68 ></nowiki>....Th
1900: 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 3c 63 69 74 e following <cit
1910: 65 3e 61 70 61 63 68 65 32 3c 2f 63 69 74 65 3e e>apache2</cite>
1920: 20 63 6f 6e 66 69 67 75 72 61 74 69 6f 6e 20 63 configuration c
1930: 61 6e 20 62 65 20 75 73 65 64 20 74 6f 20 72 75 an be used to ru
1940: 6e 20 74 68 65 20 72 6f 6f 74 20 6f 66 20 61 20 n the root of a
1950: 77 65 62 20 73 69 74 65 20 77 69 74 68 20 66 6f web site with fo
1960: 73 73 69 6c 2c 20 62 75 74 20 73 74 69 6c 6c 20 ssil, but still
1970: 61 6c 6c 6f 77 20 6f 74 68 65 72 20 73 65 72 76 allow other serv
1980: 69 63 65 73 20 2f 20 64 6f 63 75 6d 65 6e 74 73 ices / documents
1990: 20 74 6f 20 62 65 20 72 65 61 63 68 65 64 20 76 to be reached v
19a0: 69 61 20 73 70 65 63 69 66 69 63 20 55 52 4c 73 ia specific URLs
19b0: 2e 20 52 65 70 6c 61 63 65 20 22 63 6f 64 65 2e . Replace "code.
19c0: 61 75 74 6f 6e 6f 6d 6f 2e 75 73 22 20 77 69 74 autonomo.us" wit
19d0: 68 20 79 6f 75 72 20 73 69 74 65 27 73 20 6e 61 h your site's na
19e0: 6d 65 20 61 6e 64 20 22 64 63 6c 61 72 6b 40 70 me and "dclark@p
19f0: 6f 62 6f 78 2e 63 6f 6d 22 20 77 69 74 68 20 79 obox.com" with y
1a00: 6f 75 72 20 65 6d 61 69 6c 2e 0d 0a 0d 0a 3c 76 our email.....<v
1a10: 65 72 62 61 74 69 6d 3e 0d 0a 4e 61 6d 65 56 69 erbatim>..NameVi
1a20: 72 74 75 61 6c 48 6f 73 74 20 2a 3a 38 30 0d 0a rtualHost *:80..
1a30: 3c 56 69 72 74 75 61 6c 48 6f 73 74 20 2a 3a 38 <VirtualHost *:8
1a40: 30 3e 0d 0a 20 20 20 20 53 65 72 76 65 72 4e 61 0>.. ServerNa
1a50: 6d 65 20 63 6f 64 65 2e 61 75 74 6f 6e 6f 6d 6f me code.autonomo
1a60: 2e 75 73 0d 0a 20 20 20 20 53 65 72 76 65 72 41 .us.. ServerA
1a70: 64 6d 69 6e 20 64 63 6c 61 72 6b 40 70 6f 62 6f dmin dclark@pobo
1a80: 78 2e 63 6f 6d 0d 0a 20 20 20 20 45 72 72 6f 72 x.com.. Error
1a90: 4c 6f 67 20 2f 76 61 72 2f 6c 6f 67 2f 61 70 61 Log /var/log/apa
1aa0: 63 68 65 32 2f 63 6f 64 65 2e 61 75 74 6f 6e 6f che2/code.autono
1ab0: 6d 6f 2e 75 73 2d 65 72 72 6f 72 2e 6c 6f 67 0d mo.us-error.log.
1ac0: 0a 20 20 20 20 4c 6f 67 4c 65 76 65 6c 20 77 61 . LogLevel wa
1ad0: 72 6e 0d 0a 20 20 20 20 43 75 73 74 6f 6d 4c 6f rn.. CustomLo
1ae0: 67 20 2f 76 61 72 2f 6c 6f 67 2f 61 70 61 63 68 g /var/log/apach
1af0: 65 32 2f 63 6f 64 65 2e 61 75 74 6f 6e 6f 6d 6f e2/code.autonomo
1b00: 2e 75 73 2d 61 63 63 65 73 73 2e 6c 6f 67 20 63 .us-access.log c
1b10: 6f 6d 62 69 6e 65 64 0d 0a 20 20 20 20 53 65 72 ombined.. Ser
1b20: 76 65 72 53 69 67 6e 61 74 75 72 65 20 4f 6e 0d verSignature On.
1b30: 0a 0d 0a 20 20 20 20 44 6f 63 75 6d 65 6e 74 52 ... DocumentR
1b40: 6f 6f 74 20 2f 76 61 72 2f 77 77 77 2f 0d 0a 0d oot /var/www/...
1b50: 0a 20 20 20 20 53 63 72 69 70 74 41 6c 69 61 73 . ScriptAlias
1b60: 20 2f 63 67 69 2d 62 69 6e 2f 20 2f 75 73 72 2f /cgi-bin/ /usr/
1b70: 6c 69 62 2f 63 67 69 2d 62 69 6e 2f 0d 0a 20 20 lib/cgi-bin/..
1b80: 20 20 3c 44 69 72 65 63 74 6f 72 79 20 22 2f 75 <Directory "/u
1b90: 73 72 2f 6c 69 62 2f 63 67 69 2d 62 69 6e 22 3e sr/lib/cgi-bin">
1ba0: 0d 0a 20 20 20 20 20 20 20 20 41 6c 6c 6f 77 4f .. AllowO
1bb0: 76 65 72 72 69 64 65 20 4e 6f 6e 65 0d 0a 20 20 verride None..
1bc0: 20 20 20 20 20 20 4f 70 74 69 6f 6e 73 20 2b 45 Options +E
1bd0: 78 65 63 43 47 49 20 2d 4d 75 6c 74 69 56 69 65 xecCGI -MultiVie
1be0: 77 73 20 2b 53 79 6d 4c 69 6e 6b 73 49 66 4f 77 ws +SymLinksIfOw
1bf0: 6e 65 72 4d 61 74 63 68 0d 0a 20 20 20 20 20 20 nerMatch..
1c00: 20 20 4f 72 64 65 72 20 61 6c 6c 6f 77 2c 64 65 Order allow,de
1c10: 6e 79 0d 0a 20 20 20 20 20 20 20 20 41 6c 6c 6f ny.. Allo
1c20: 77 20 66 72 6f 6d 20 61 6c 6c 0d 0a 20 20 20 20 w from all..
1c30: 3c 2f 44 69 72 65 63 74 6f 72 79 3e 0d 0a 0d 0a </Directory>....
1c40: 20 20 20 20 23 20 46 6f 73 73 69 6c 20 53 43 4d # Fossil SCM
1c50: 20 61 74 20 72 6f 6f 74 20 6f 66 20 77 65 62 20 at root of web
1c60: 73 69 74 65 20 28 68 74 74 70 3a 2f 2f 65 78 61 site (http://exa
1c70: 6d 70 6c 65 2e 63 6f 6d 29 20 63 6f 6e 66 69 67 mple.com) config
1c80: 75 72 61 74 69 6f 6e 2e 2e 2e 0d 0a 20 20 20 20 uration.....
1c90: 52 65 77 72 69 74 65 45 6e 67 69 6e 65 20 4f 6e RewriteEngine On
1ca0: 0d 0a 20 20 20 20 23 20 52 65 77 72 69 74 65 43 .. # RewriteC
1cb0: 6f 6e 64 20 2d 20 4f 6e 65 20 66 6f 72 20 65 76 ond - One for ev
1cc0: 65 72 79 20 55 52 4c 20 77 65 20 64 6f 6e 27 74 ery URL we don't
1cd0: 20 77 61 6e 74 20 46 6f 73 73 69 6c 20 53 43 4d want Fossil SCM
1ce0: 20 74 6f 20 73 65 72 76 65 2e 20 49 6e 20 74 68 to serve. In th
1cf0: 65 0d 0a 20 20 20 20 23 20 20 20 20 20 20 20 20 e.. #
1d00: 20 20 20 20 20 20 20 65 78 61 6d 70 6c 65 2c 20 example,
1d10: 72 65 71 75 65 73 74 73 20 74 68 61 74 20 67 6f requests that go
1d20: 20 74 6f 20 74 68 65 20 2f 76 61 72 2f 77 77 77 to the /var/www
1d30: 2f 74 6d 70 20 64 69 72 65 63 74 6f 72 79 20 61 /tmp directory a
1d40: 6e 64 20 0d 0a 20 20 20 20 23 20 20 20 20 20 20 nd .. #
1d50: 20 20 20 20 20 20 20 20 20 74 68 65 20 2f 75 73 the /us
1d60: 72 2f 6c 69 62 2f 63 67 69 2d 62 69 6e 20 64 69 r/lib/cgi-bin di
1d70: 72 65 63 74 6f 74 79 20 61 72 65 20 69 67 6e 6f rectoty are igno
1d80: 72 65 64 20 62 79 20 46 6f 73 73 69 6c 20 53 43 red by Fossil SC
1d90: 4d 2e 0d 0a 20 20 20 20 52 65 77 72 69 74 65 43 M... RewriteC
1da0: 6f 6e 64 20 25 7b 52 45 51 55 45 53 54 5f 55 52 ond %{REQUEST_UR
1db0: 49 7d 20 21 5e 2f 74 6d 70 2f 2e 2a 24 0d 0a 20 I} !^/tmp/.*$..
1dc0: 20 20 20 52 65 77 72 69 74 65 43 6f 6e 64 20 25 RewriteCond %
1dd0: 7b 52 45 51 55 45 53 54 5f 55 52 49 7d 20 21 5e {REQUEST_URI} !^
1de0: 2f 63 67 69 2d 62 69 6e 2f 2e 2a 24 0d 0a 20 20 /cgi-bin/.*$..
1df0: 20 20 52 65 77 72 69 74 65 52 75 6c 65 20 5e 28 RewriteRule ^(
1e00: 2e 2a 29 24 20 2f 75 73 72 2f 6c 69 62 2f 63 67 .*)$ /usr/lib/cg
1e10: 69 2d 62 69 6e 2f 63 6f 64 65 2e 61 75 74 6f 6e i-bin/code.auton
1e20: 6f 6d 6f 2e 75 73 2f 24 31 20 5b 54 3d 61 70 70 omo.us/$1 [T=app
1e30: 6c 69 63 61 74 69 6f 6e 2f 78 2d 68 74 74 70 64 lication/x-httpd
1e40: 2d 63 67 69 5d 0d 0a 3c 2f 56 69 72 74 75 61 6c -cgi]..</Virtual
1e50: 48 6f 73 74 3e 0d 0a 3c 2f 76 65 72 62 61 74 69 Host>..</verbati
1e60: 6d 3e 0d 0a 0d 0a 2f 75 73 72 2f 6c 69 62 2f 63 m>..../usr/lib/c
1e70: 67 69 2d 62 69 6e 2f 63 6f 64 65 2e 61 75 74 6f gi-bin/code.auto
1e80: 6e 6f 6d 6f 2e 75 73 20 69 73 20 6a 75 73 74 20 nomo.us is just
1e90: 61 20 73 74 61 6e 64 61 72 64 20 66 6f 73 73 69 a standard fossi
1ea0: 6c 20 43 47 49 20 66 69 6c 65 3b 20 69 74 20 6c l CGI file; it l
1eb0: 6f 6f 6b 73 20 6c 69 6b 65 20 74 68 69 73 3a 0d ooks like this:.
1ec0: 0a 0d 0a 3c 76 65 72 62 61 74 69 6d 3e 0d 0a 23 ...<verbatim>..#
1ed0: 21 2f 75 73 72 2f 62 69 6e 2f 66 6f 73 73 69 6c !/usr/bin/fossil
1ee0: 0d 0a 72 65 70 6f 73 69 74 6f 72 79 3a 20 2f 73 ..repository: /s
1ef0: 72 76 2f 66 6f 73 73 69 6c 2d 73 63 6d 2f 63 6f rv/fossil-scm/co
1f00: 64 65 2e 61 75 74 6f 6e 6f 6d 6f 2e 75 73 2e 66 de.autonomo.us.f
1f10: 6f 73 73 69 6c 2d 73 63 6d 0d 0a 3c 2f 76 65 72 ossil-scm..</ver
1f20: 62 61 74 69 6d 3e 0d 0a 0d 0a 3c 68 34 3e 57 69 batim>....<h4>Wi
1f30: 6e 64 6f 77 73 3c 2f 68 34 3e 0d 0a 3c 70 3e 57 ndows</h4>..<p>W
1f40: 68 69 6c 65 20 69 74 20 69 73 20 66 61 72 20 66 hile it is far f
1f50: 72 6f 6d 20 61 20 70 65 72 66 65 63 74 20 73 65 rom a perfect se
1f60: 74 20 6f 66 20 69 6e 73 74 72 75 63 74 69 6f 6e t of instruction
1f70: 73 2e 2e 20 68 65 72 65 20 61 72 65 20 73 6f 6d s.. here are som
1f80: 65 20 71 75 69 63 6b 20 6e 6f 74 65 73 20 74 68 e quick notes th
1f90: 61 74 20 73 68 6f 75 6c 64 20 68 65 6c 70 20 77 at should help w
1fa0: 69 6e 64 6f 77 73 20 75 73 65 72 73 20 61 6c 6f indows users alo
1fb0: 6e 67 20 74 68 65 20 77 61 79 2e 2e 2e 3c 2f 70 ng the way...</p
1fc0: 3e 0d 0a 3c 75 6c 3e 0d 0a 3c 6c 69 3e 79 6f 75 >..<ul>..<li>you
1fd0: 20 6e 65 65 64 20 66 6f 73 73 69 6c 2e 65 78 65 need fossil.exe
1fe0: 20 61 63 63 65 73 73 69 62 6c 65 20 62 79 20 79 accessible by y
1ff0: 6f 75 72 20 77 65 62 20 73 65 72 76 65 72 20 6f our web server o
2000: 72 20 6f 6e 20 79 6f 75 72 20 70 61 74 68 2e 2e r on your path..
2010: 20 65 61 73 69 65 73 74 20 69 73 20 74 6f 20 6a easiest is to j
2020: 75 73 74 20 63 68 75 63 6b 20 69 74 20 69 6e 20 ust chuck it in
2030: 5c 25 53 59 53 54 45 4d 5f 52 4f 4f 54 25 5c 20 \%SYSTEM_ROOT%\
2040: 28 75 73 75 61 6c 6c 79 20 63 3a 5c 77 69 6e 64 (usually c:\wind
2050: 6f 77 73 5c 29 20 3c 2f 6c 69 3e 0d 0a 3c 6c 69 ows\) </li>..<li
2060: 3e 61 73 73 75 6d 69 6e 67 20 79 6f 75 20 61 72 >assuming you ar
2070: 65 20 72 75 6e 6e 69 6e 67 20 61 70 61 63 68 65 e running apache
2080: 2c 20 79 6f 75 20 6e 65 65 64 20 74 6f 20 65 69 , you need to ei
2090: 74 68 65 72 20 61 64 64 20 74 68 65 20 45 78 65 ther add the Exe
20a0: 63 43 47 49 20 74 6f 20 74 68 65 20 6f 70 74 69 cCGI to the opti
20b0: 6f 6e 73 20 6f 6e 20 79 6f 75 72 20 44 6f 63 75 ons on your Docu
20c0: 6d 65 6e 74 52 6f 6f 74 2c 20 6f 72 20 6d 61 6b mentRoot, or mak
20d0: 65 20 73 75 72 65 20 74 68 65 20 53 63 72 69 70 e sure the Scrip
20e0: 74 41 6c 69 61 73 20 64 69 72 65 63 74 69 76 65 tAlias directive
20f0: 20 69 73 20 73 65 74 20 61 6e 64 20 70 75 74 20 is set and put
2100: 79 6f 75 72 20 2e 63 67 69 20 66 69 6c 65 73 20 your .cgi files
2110: 69 6e 20 74 68 61 74 20 66 6f 6c 64 65 72 2e 2e in that folder..
2120: 3c 2f 6c 69 3e 0d 0a 3c 6c 69 3e 74 68 65 20 63 </li>..<li>the c
2130: 6f 6e 74 65 6e 74 73 20 6f 66 20 79 6f 75 72 20 ontents of your
2140: 63 67 69 20 66 69 6c 65 20 6e 65 65 64 73 20 74 cgi file needs t
2150: 6f 20 65 73 73 65 6e 74 69 61 6c 6c 79 20 74 68 o essentially th
2160: 65 20 73 61 6d 65 20 61 73 20 61 62 6f 76 65 2e e same as above.
2170: 2e 20 68 6f 77 65 76 65 72 20 70 61 74 68 73 20 . however paths
2180: 6e 65 65 64 73 20 74 6f 20 62 65 20 77 69 6e 64 needs to be wind
2190: 6f 77 73 20 66 72 69 65 6e 64 6c 79 2e 2e 20 69 ows friendly.. i
21a0: 20 68 61 76 65 20 6d 61 64 65 20 73 75 72 65 20 have made sure
21b0: 74 68 61 74 20 61 6c 6c 20 66 6f 6c 64 65 72 73 that all folders
21c0: 20 6f 6e 20 6d 79 20 74 65 73 74 20 62 6f 78 20 on my test box
21d0: 61 72 65 20 66 72 65 65 20 6f 66 20 73 70 61 63 are free of spac
21e0: 65 73 2c 20 61 6e 64 20 61 73 20 73 75 63 68 20 es, and as such
21f0: 74 68 69 73 20 66 69 6c 65 20 77 6f 72 6b 73 20 this file works
2200: 66 6f 72 20 6d 65 20 28 6f 62 76 69 6f 75 73 6c for me (obviousl
2210: 79 20 79 6f 75 72 20 70 61 74 68 73 20 6d 61 79 y your paths may
2220: 20 64 69 66 66 65 72 29 0d 0a 3c 70 72 65 3e 0d differ)..<pre>.
2230: 0a 23 21 20 66 6f 73 73 69 6c 2e 65 78 65 0d 0a .#! fossil.exe..
2240: 72 65 70 6f 73 69 74 6f 72 79 3a 20 63 3a 2f 77 repository: c:/w
2250: 61 6d 70 2f 77 77 77 2f 64 65 76 2f 61 63 63 6f amp/www/dev/acco
2260: 75 6e 74 73 2e 66 6f 73 73 69 6c 0d 0a 3c 2f 70 unts.fossil..</p
2270: 72 65 3e 0d 0a 49 20 73 75 70 70 6f 73 65 20 79 re>..I suppose y
2280: 6f 75 20 63 6f 75 6c 64 20 70 75 74 20 66 6f 73 ou could put fos
2290: 73 69 6c 2e 65 78 65 20 73 6f 6d 65 77 68 65 72 sil.exe somewher
22a0: 65 20 6d 6f 72 65 20 73 70 65 63 69 66 69 63 20 e more specific
22b0: 61 6e 64 20 73 65 74 20 74 68 65 20 70 61 74 68 and set the path
22c0: 20 74 6f 20 69 74 20 61 73 20 77 65 6c 6c 2c 20 to it as well,
22d0: 62 75 74 20 73 69 6e 63 65 20 79 6f 75 20 61 72 but since you ar
22e0: 65 20 70 72 6f 62 61 62 6c 79 20 75 73 69 6e 67 e probably using
22f0: 20 74 68 65 20 73 61 6d 65 20 65 78 65 63 75 74 the same execut
2300: 61 62 6c 65 20 66 6f 72 20 63 6d 64 6c 69 6e 65 able for cmdline
2310: 20 61 6e 64 20 63 67 69 20 69 74 20 6b 69 6e 64 and cgi it kind
2320: 20 6f 66 20 6a 75 73 74 20 6d 61 6b 65 73 20 73 of just makes s
2330: 65 6e 73 65 20 74 6f 20 70 75 74 20 69 74 20 73 ense to put it s
2340: 6f 6d 65 77 68 65 72 65 20 6d 6f 72 65 20 61 63 omewhere more ac
2350: 63 65 73 73 69 62 6c 65 3c 2f 6c 69 3e 0d 0a 3c cessible</li>..<
2360: 6c 69 3e 41 73 20 77 69 74 68 20 6d 6f 73 74 20 li>As with most
2370: 57 69 6e 64 6f 77 73 20 62 61 73 65 64 20 77 65 Windows based we
2380: 62 20 69 6e 73 74 72 75 63 74 69 6f 6e 73 2c 20 b instructions,
2390: 70 65 72 6d 69 73 73 69 6f 6e 20 61 72 65 20 6e permission are n
23a0: 6f 74 20 61 73 20 69 6d 70 6f 72 74 61 6e 74 2c ot as important,
23b0: 20 68 6f 77 65 76 65 72 20 61 74 20 74 68 65 20 however at the
23c0: 6c 65 61 73 74 2c 20 79 6f 75 20 6e 65 65 64 20 least, you need
23d0: 74 6f 20 6d 61 6b 65 20 73 75 72 65 20 74 68 61 to make sure tha
23e0: 74 20 79 6f 75 72 20 72 65 70 6f 73 69 74 6f 72 t your repositor
23f0: 79 20 69 73 20 6e 6f 74 20 66 6c 61 67 67 65 64 y is not flagged
2400: 20 72 65 61 64 2d 6f 6e 6c 79 2c 20 61 73 20 79 read-only, as y
2410: 6f 75 20 77 69 6c 6c 20 65 6e 63 6f 75 6e 74 65 ou will encounte
2420: 72 20 64 61 74 61 62 61 73 65 20 65 72 72 6f 72 r database error
2430: 73 20 69 66 20 69 74 20 69 73 2e 3c 2f 6c 69 3e s if it is.</li>
2440: 0d 0a 3c 2f 75 6c 3e 0d 0a 0d 0a 3c 68 33 3e 44 ..</ul>....<h3>D
2450: 69 73 63 75 73 73 69 6f 6e 3c 2f 68 33 3e 0d 0a iscussion</h3>..
2460: 55 73 69 6e 67 20 74 68 65 20 43 47 49 20 73 65 Using the CGI se
2470: 72 76 65 72 20 69 73 20 74 68 65 20 62 65 73 74 rver is the best
2480: 20 73 6f 6c 75 74 69 6f 6e 20 63 6f 6d 62 69 6e solution combin
2490: 69 6e 67 20 61 6e 20 65 78 69 73 74 69 6e 67 20 ing an existing
24a0: 77 65 62 20 69 6e 66 72 61 73 74 72 75 63 74 75 web infrastructu
24b0: 72 65 20 61 6e 64 20 74 68 65 20 73 68 61 72 69 re and the shari
24c0: 6e 67 20 6f 66 20 6d 61 6e 79 20 3c 63 69 74 65 ng of many <cite
24d0: 3e 46 6f 73 73 69 6c 3c 2f 63 69 74 65 3e 20 72 >Fossil</cite> r
24e0: 65 70 6f 73 69 74 6f 72 69 65 73 2e 20 20 55 6e epositories. Un
24f0: 6c 69 6b 65 20 74 68 65 20 61 64 2d 68 6f 63 20 like the ad-hoc
2500: 73 6f 6c 75 74 69 6f 6e 20 77 68 69 63 68 20 72 solution which r
2510: 65 71 75 69 72 65 73 2c 20 69 6e 20 65 66 66 65 equires, in effe
2520: 63 74 2c 20 61 20 73 65 70 61 72 61 74 65 20 70 ct, a separate p
2530: 6f 72 74 20 66 6f 72 20 65 61 63 68 20 73 69 6d ort for each sim
2540: 75 6c 74 61 6e 65 6f 75 73 6c 79 2d 73 68 61 72 ultaneously-shar
2550: 65 64 20 72 65 70 6f 73 69 74 6f 72 79 2c 20 61 ed repository, a
2560: 6e 64 20 77 68 69 63 68 20 72 65 71 75 69 72 65 nd which require
2570: 73 20 73 65 76 65 72 61 6c 20 69 6e 73 74 61 6e s several instan
2580: 63 65 73 20 6f 66 20 66 6f 73 73 69 6c 20 72 75 ces of fossil ru
2590: 6e 6e 69 6e 67 20 2d 2d 20 6f 6e 65 20 66 6f 72 nning -- one for
25a0: 20 65 61 63 68 20 73 68 61 72 65 64 20 72 65 70 each shared rep
25b0: 6f 73 69 74 6f 72 79 20 2d 2d 20 74 68 65 20 43 ository -- the C
25c0: 47 49 20 61 70 70 72 6f 61 63 68 20 75 73 65 73 GI approach uses
25d0: 20 55 52 4c 73 20 74 6f 20 64 69 73 74 69 6e 67 URLs to disting
25e0: 75 69 73 68 20 62 65 74 77 65 65 6e 20 72 65 70 uish between rep
25f0: 6f 73 69 74 6f 72 69 65 73 20 61 6e 64 20 6f 6e ositories and on
2600: 6c 79 20 28 62 72 69 65 66 6c 79 29 20 72 75 6e ly (briefly) run
2610: 73 20 61 20 63 6f 70 79 20 6f 66 20 66 6f 73 73 s a copy of foss
2620: 69 6c 20 77 68 65 6e 20 74 68 65 20 72 65 70 6f il when the repo
2630: 73 69 74 6f 72 79 20 69 73 20 61 63 74 75 61 6c sitory is actual
2640: 6c 79 20 61 63 63 65 73 73 65 64 2e 0d 0a 0d 0a ly accessed.....
2650: 53 68 61 72 69 6e 67 20 72 65 70 6f 73 69 74 6f Sharing reposito
2660: 72 69 65 73 20 77 69 74 68 20 43 47 49 20 69 73 ries with CGI is
2670: 20 72 65 61 6c 6c 79 20 6f 6e 6c 79 20 77 6f 72 really only wor
2680: 74 68 20 74 68 65 20 65 66 66 6f 72 74 20 69 66 th the effort if
2690: 20 6d 6f 72 65 20 74 68 61 6e 20 6f 6e 65 20 72 more than one r
26a0: 65 70 6f 73 69 74 6f 72 79 20 69 73 20 62 65 69 epository is bei
26b0: 6e 67 20 73 68 61 72 65 64 2c 20 68 6f 77 65 76 ng shared, howev
26c0: 65 72 2e 20 20 57 69 74 68 20 6f 6e 6c 79 20 6f er. With only o
26d0: 6e 65 20 62 65 69 6e 67 20 73 68 61 72 65 64 2c ne being shared,
26e0: 20 3c 63 6f 64 65 3e 66 6f 73 73 69 6c 20 73 65 <code>fossil se
26f0: 72 76 65 72 3c 2f 63 6f 64 65 3e 20 69 73 20 6c rver</code> is l
2700: 69 6b 65 6c 79 20 6d 6f 72 65 20 74 68 61 6e 20 ikely more than
2710: 61 64 65 71 75 61 74 65 20 6f 72 20 74 68 65 20 adequate or the
2720: 75 73 65 20 6f 66 20 28 78 29 69 6e 65 74 64 20 use of (x)inetd
2730: 6d 61 79 20 62 65 20 69 6e 64 69 63 61 74 65 64 may be indicated
2740: 2e 20 20 49 66 2c 20 68 6f 77 65 76 65 72 2c 20 . If, however,
2750: 74 68 65 72 65 20 69 73 20 61 6c 72 65 61 64 79 there is already
2760: 20 61 6e 20 65 78 69 73 74 69 6e 67 20 77 65 62 an existing web
2770: 20 69 6e 66 72 61 73 74 72 75 63 74 75 72 65 20 infrastructure
2780: 69 6e 20 70 6c 61 63 65 2c 20 43 47 49 20 73 74 in place, CGI st
2790: 69 6c 6c 20 6d 61 79 20 62 65 20 70 72 65 66 65 ill may be prefe
27a0: 72 72 65 64 20 69 66 20 6f 6e 6c 79 20 66 6f 72 rred if only for
27b0: 20 63 6f 6e 73 69 73 74 65 6e 63 79 20 61 6e 64 consistency and
27c0: 20 6d 61 69 6e 74 61 69 6e 61 62 69 6c 69 74 79 maintainability
27d0: 20 6f 66 20 74 68 65 20 73 79 73 74 65 6d 20 61 of the system a
27e0: 73 20 61 20 77 68 6f 6c 65 2e 0d 0a 0d 0a 3c 68 s a whole.....<h
27f0: 32 3e 3c 61 20 6e 61 6d 65 3d 22 65 6e 76 22 3e 2><a name="env">
2800: 55 73 69 6e 67 20 45 6e 76 69 72 6f 6e 6d 65 6e Using Environmen
2810: 74 20 76 61 72 69 61 62 6c 65 73 3c 2f 61 3e 3c t variables</a><
2820: 2f 68 32 3e 0d 0a 3c 68 33 3e 4d 6f 74 69 76 61 /h2>..<h3>Motiva
2830: 74 69 6f 6e 3c 2f 68 33 3e 0d 0a 20 20 2a 20 20 tion</h3>.. *
2840: 57 61 6e 74 20 74 6f 20 75 73 65 20 61 20 64 69 Want to use a di
2850: 66 66 65 72 65 6e 74 20 65 64 69 74 6f 72 20 66 fferent editor f
2860: 6f 72 20 63 68 65 63 6b 69 6e 73 20 28 55 6e 69 or checkins (Uni
2870: 78 2f 57 69 6e 64 6f 77 73 29 0d 0a 20 20 2a 20 x/Windows).. *
2880: 20 55 73 65 20 61 20 70 72 6f 78 79 20 69 66 20 Use a proxy if
2890: 79 6f 75 20 61 72 65 20 62 65 68 69 6e 64 20 61 you are behind a
28a0: 20 66 69 72 65 77 61 6c 6c 0d 0a 0d 0a 3c 68 33 firewall....<h3
28b0: 3e 53 6f 6c 75 74 69 6f 6e 3c 2f 68 33 3e 0d 0a >Solution</h3>..
28c0: 45 6e 76 69 72 6f 6e 6d 65 6e 74 20 76 61 72 69 Environment vari
28d0: 61 62 6c 65 73 20 61 72 65 20 75 73 65 64 20 74 ables are used t
28e0: 6f 20 63 75 73 74 6f 6d 69 7a 65 20 73 6f 6d 65 o customize some
28f0: 20 70 72 6f 67 72 61 6d 6d 65 20 62 65 68 61 76 programme behav
2900: 69 6f 75 72 2e 20 4f 6e 20 4c 69 6e 75 78 2f 55 iour. On Linux/U
2910: 6e 69 78 20 74 68 65 79 20 63 61 6e 20 62 65 20 nix they can be
2920: 73 65 74 20 69 6e 20 79 6f 75 20 7e 2f 2e 62 61 set in you ~/.ba
2930: 73 68 72 63 20 6f 72 20 65 76 65 6e 20 6f 6e 20 shrc or even on
2940: 63 6f 6d 6d 61 6e 64 20 6c 69 6e 65 2e 20 4f 6e command line. On
2950: 20 57 69 6e 64 6f 77 73 20 74 68 65 79 20 63 61 Windows they ca
2960: 6e 20 62 65 20 73 65 74 20 69 6e 20 74 68 65 20 n be set in the
2970: 73 79 73 74 65 6d 20 73 65 74 74 69 6e 67 73 2e system settings.
2980: 0d 0a 0d 0a 3c 63 69 74 65 3e 46 6f 73 73 69 6c ....<cite>Fossil
2990: 3c 2f 63 69 74 65 3e 20 63 68 65 63 6b 73 20 74 </cite> checks t
29a0: 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 65 6e 76 he following env
29b0: 69 72 6f 6e 6d 65 6e 74 20 76 61 72 69 61 62 6c ironment variabl
29c0: 65 73 3a 0d 0a 20 20 2a 20 20 56 49 53 55 41 4c es:.. * VISUAL
29d0: 2f 45 44 49 54 4f 52 0d 0a 20 20 2a 20 20 68 74 /EDITOR.. * ht
29e0: 74 70 5f 70 72 6f 78 79 0d 0a 20 20 2a 20 20 54 tp_proxy.. * T
29f0: 4d 50 5f 44 49 52 0d 0a 20 20 2a 20 20 47 41 54 MP_DIR.. * GAT
2a00: 45 57 41 59 5f 49 4e 54 45 52 46 41 43 45 0d 0a EWAY_INTERFACE..
2a10: 20 20 2a 20 20 53 51 4c 49 54 45 5f 46 4f 52 43 * SQLITE_FORC
2a20: 45 5f 50 52 4f 58 59 5f 4c 4f 43 4b 49 4e 47 0d E_PROXY_LOCKING.
2a30: 0a 20 20 2a 20 20 55 53 45 52 0d 0a 20 20 2a 20 . * USER.. *
2a40: 20 55 53 45 52 4e 41 4d 45 0d 0a 0d 0a 3c 62 3e USERNAME....<b>
2a50: 56 49 53 55 41 4c 2f 45 44 49 54 4f 52 3c 2f 62 VISUAL/EDITOR</b
2a60: 3e 20 63 6f 6e 74 61 69 6e 20 74 68 65 20 65 64 > contain the ed
2a70: 69 74 6f 72 20 6f 66 20 79 6f 75 72 20 63 68 6f itor of your cho
2a80: 69 63 65 20 74 68 61 74 20 69 73 20 75 73 65 64 ice that is used
2a90: 20 74 6f 20 77 72 69 74 65 20 74 68 65 20 63 6f to write the co
2aa0: 6d 6d 69 74 20 66 69 6c 65 2e 0d 0a 0d 0a 3c 62 mmit file.....<b
2ab0: 3e 54 4d 50 5f 44 49 52 3c 2f 62 3e 20 73 70 65 >TMP_DIR</b> spe
2ac0: 63 69 66 69 65 73 20 74 68 65 20 64 69 72 65 63 cifies the direc
2ad0: 74 6f 72 79 20 66 6f 72 20 74 65 6d 70 6f 72 61 tory for tempora
2ae0: 72 79 20 66 69 6c 65 73 2e 0d 0a 0d 0a 3c 62 3e ry files.....<b>
2af0: 47 41 54 45 57 41 59 5f 49 4e 54 45 52 46 41 43 GATEWAY_INTERFAC
2b00: 45 3c 2f 62 3e 20 3f 3f 3f 0d 0a 0d 0a 3c 62 3e E</b> ???....<b>
2b10: 53 51 4c 49 54 45 5f 46 4f 52 43 45 5f 50 52 4f SQLITE_FORCE_PRO
2b20: 58 59 5f 4c 4f 43 4b 49 4e 47 3c 2f 62 3e 20 3f XY_LOCKING</b> ?
2b30: 3f 3f 0d 0a 0d 0a 3c 62 3e 55 53 45 52 3c 2f 62 ??....<b>USER</b
2b40: 3e 0d 0a 0d 0a 3c 62 3e 55 53 45 52 4e 41 4d 45 >....<b>USERNAME
2b50: 3c 2f 62 3e 0d 0a 0d 0a 0d 0a 3c 68 32 3e 3c 61 </b>......<h2><a
2b60: 20 6e 61 6d 65 3d 22 63 73 73 22 3e 3c 2f 61 3e name="css"></a>
2b70: 45 78 61 6d 70 6c 65 20 43 53 53 3c 2f 68 32 3e Example CSS</h2>
2b80: 0d 0a 3c 68 33 3e 4d 6f 74 69 76 61 74 69 6f 6e ..<h3>Motivation
2b90: 3c 2f 68 33 3e 0d 0a 54 68 65 20 64 65 66 61 75 </h3>..The defau
2ba0: 6c 74 20 55 49 20 6d 61 79 20 6e 6f 74 20 62 65 lt UI may not be
2bb0: 20 73 74 79 6c 69 73 68 20 69 6e 20 65 76 65 72 stylish in ever
2bc0: 79 6f 6e 65 73 20 65 79 65 73 2e 0d 0a 49 74 20 yones eyes...It
2bd0: 69 73 20 75 70 20 74 6f 20 79 6f 75 20 74 6f 20 is up to you to
2be0: 63 68 61 6e 67 65 20 69 74 2e 20 53 65 65 20 74 change it. See t
2bf0: 68 65 20 43 53 53 20 63 6f 64 65 20 62 65 6c 6f he CSS code belo
2c00: 77 20 66 72 6f 6d 20 74 68 69 73 20 73 69 74 65 w from this site
2c10: 20 5b 68 74 74 70 3a 2f 2f 66 6f 73 73 69 6c 2e [http://fossil.
2c20: 77 61 6e 64 65 72 69 6e 67 68 6f 72 73 65 2e 6e wanderinghorse.n
2c30: 65 74 2f 69 6e 64 65 78 2e 63 67 69 2f 69 6e 64 et/index.cgi/ind
2c40: 65 78 7c 57 61 6e 64 65 72 69 6e 67 20 48 6f 72 ex|Wandering Hor
2c50: 73 65 5d 0d 0a 0d 0a 3c 6e 6f 77 69 6b 69 3e 0d se]....<nowiki>.
2c60: 0a 3c 70 72 65 3e 0d 0a 2f 2a 20 47 65 6e 65 72 .<pre>../* Gener
2c70: 61 6c 20 73 65 74 74 69 6e 67 73 20 66 6f 72 20 al settings for
2c80: 74 68 65 20 65 6e 74 69 72 65 20 70 61 67 65 20 the entire page
2c90: 2a 2f 0d 0a 62 6f 64 79 20 7b 0d 0a 20 20 6d 61 */..body {.. ma
2ca0: 72 67 69 6e 3a 20 30 65 78 20 31 65 78 3b 0d 0a rgin: 0ex 1ex;..
2cb0: 20 20 70 61 64 64 69 6e 67 3a 20 30 70 78 3b 0d padding: 0px;.
2cc0: 0a 20 20 62 61 63 6b 67 72 6f 75 6e 64 2d 63 6f . background-co
2cd0: 6c 6f 72 3a 20 77 68 69 74 65 3b 0d 0a 20 20 66 lor: white;.. f
2ce0: 6f 6e 74 2d 66 61 6d 69 6c 79 3a 20 22 73 61 6e ont-family: "san
2cf0: 73 20 73 65 72 69 66 22 3b 0d 0a 7d 0d 0a 0d 0a s serif";..}....
2d00: 2f 2a 20 4d 61 6b 65 20 74 68 65 20 6c 69 6e 6b /* Make the link
2d10: 73 20 69 6e 20 74 68 65 20 66 6f 6f 74 65 72 20 s in the footer
2d20: 6c 65 73 73 20 75 67 6c 79 2e 2e 2e 20 2a 2f 0d less ugly... */.
2d30: 0a 61 20 7b 20 63 6f 6c 6f 72 3a 20 23 30 30 30 .a { color: #000
2d40: 66 36 61 3b 20 7d 0d 0a 61 3a 6c 69 6e 6b 20 7b f6a; }..a:link {
2d50: 20 63 6f 6c 6f 72 3a 20 23 30 30 30 66 36 61 3b color: #000f6a;
2d60: 20 7d 0d 0a 61 3a 76 69 73 69 74 65 64 20 7b 20 }..a:visited {
2d70: 63 6f 6c 6f 72 3a 20 23 30 30 30 66 36 61 3b 20 color: #000f6a;
2d80: 7d 0d 0a 61 3a 68 6f 76 65 72 20 7b 20 62 61 63 }..a:hover { bac
2d90: 6b 67 72 6f 75 6e 64 2d 63 6f 6c 6f 72 3a 20 23 kground-color: #
2da0: 65 33 65 33 65 33 3b 20 7d 0d 0a 0d 0a 0d 0a 68 e3e3e3; }......h
2db0: 72 20 7b 0d 0a 20 20 68 65 69 67 68 74 3a 20 33 r {.. height: 3
2dc0: 70 78 3b 0d 0a 20 20 62 6f 72 64 65 72 2d 74 6f px;.. border-to
2dd0: 70 3a 20 6e 6f 6e 65 3b 20 2f 2a 31 70 78 20 64 p: none; /*1px d
2de0: 61 73 68 65 64 20 23 30 30 35 3b 2a 2f 0d 0a 20 ashed #005;*/..
2df0: 20 62 6f 72 64 65 72 2d 62 6f 74 74 6f 6d 3a 20 border-bottom:
2e00: 31 70 78 20 64 61 73 68 65 64 20 23 30 30 35 3b 1px dashed #005;
2e10: 0d 0a 20 20 62 6f 72 64 65 72 2d 6c 65 66 74 3a .. border-left:
2e20: 20 6e 6f 6e 65 3b 0d 0a 20 20 62 6f 72 64 65 72 none;.. border
2e30: 2d 72 69 67 68 74 3a 20 6e 6f 6e 65 3b 0d 0a 7d -right: none;..}
2e40: 0d 0a 2f 2a 20 54 68 65 20 70 72 6f 6a 65 63 74 ../* The project
2e50: 20 6c 6f 67 6f 20 69 6e 20 74 68 65 20 75 70 70 logo in the upp
2e60: 65 72 20 6c 65 66 74 2d 68 61 6e 64 20 63 6f 72 er left-hand cor
2e70: 6e 65 72 20 6f 66 20 65 61 63 68 20 70 61 67 65 ner of each page
2e80: 20 2a 2f 0d 0a 64 69 76 2e 6c 6f 67 6f 20 7b 0d */..div.logo {.
2e90: 0a 20 20 64 69 73 70 6c 61 79 3a 20 74 61 62 6c . display: tabl
2ea0: 65 2d 63 65 6c 6c 3b 0d 0a 20 20 74 65 78 74 2d e-cell;.. text-
2eb0: 61 6c 69 67 6e 3a 20 63 65 6e 74 65 72 3b 0d 0a align: center;..
2ec0: 20 20 76 65 72 74 69 63 61 6c 2d 61 6c 69 67 6e vertical-align
2ed0: 3a 20 62 6f 74 74 6f 6d 3b 0d 0a 20 20 63 6f 6c : bottom;.. col
2ee0: 6f 72 3a 20 23 30 30 30 66 36 61 3b 0d 0a 7d 0d or: #000f6a;..}.
2ef0: 0a 0d 0a 2f 2a 20 54 68 65 20 70 61 67 65 20 74 .../* The page t
2f00: 69 74 6c 65 20 63 65 6e 74 65 72 65 64 20 61 74 itle centered at
2f10: 20 74 68 65 20 74 6f 70 20 6f 66 20 65 61 63 68 the top of each
2f20: 20 70 61 67 65 20 2a 2f 0d 0a 64 69 76 2e 74 69 page */..div.ti
2f30: 74 6c 65 20 7b 0d 0a 20 20 64 69 73 70 6c 61 79 tle {.. display
2f40: 3a 20 74 61 62 6c 65 2d 63 65 6c 6c 3b 0d 0a 20 : table-cell;..
2f50: 20 66 6f 6e 74 2d 73 69 7a 65 3a 20 32 65 6d 3b font-size: 2em;
2f60: 0d 0a 20 20 66 6f 6e 74 2d 77 65 69 67 68 74 3a .. font-weight:
2f70: 20 62 6f 6c 64 3b 0d 0a 20 20 74 65 78 74 2d 61 bold;.. text-a
2f80: 6c 69 67 6e 3a 20 63 65 6e 74 65 72 3b 0d 0a 20 lign: center;..
2f90: 20 63 6f 6c 6f 72 3a 20 23 30 30 30 66 36 61 3b color: #000f6a;
2fa0: 0d 0a 20 20 76 65 72 74 69 63 61 6c 2d 61 6c 69 .. vertical-ali
2fb0: 67 6e 3a 20 62 6f 74 74 6f 6d 3b 0d 0a 20 20 77 gn: bottom;.. w
2fc0: 69 64 74 68 3a 20 31 30 30 25 3b 0d 0a 7d 0d 0a idth: 100%;..}..
2fd0: 0d 0a 2f 2a 20 54 68 65 20 6c 6f 67 69 6e 20 73 ../* The login s
2fe0: 74 61 74 75 73 20 6d 65 73 73 61 67 65 20 69 6e tatus message in
2ff0: 20 74 68 65 20 74 6f 70 20 72 69 67 68 74 2d 68 the top right-h
3000: 61 6e 64 20 63 6f 72 6e 65 72 20 2a 2f 0d 0a 64 and corner */..d
3010: 69 76 2e 73 74 61 74 75 73 20 7b 0d 0a 20 20 64 iv.status {.. d
3020: 69 73 70 6c 61 79 3a 20 74 61 62 6c 65 2d 63 65 isplay: table-ce
3030: 6c 6c 3b 0d 0a 20 20 74 65 78 74 2d 61 6c 69 67 ll;.. text-alig
3040: 6e 3a 20 72 69 67 68 74 3b 0d 0a 20 20 76 65 72 n: right;.. ver
3050: 74 69 63 61 6c 2d 61 6c 69 67 6e 3a 20 62 6f 74 tical-align: bot
3060: 74 6f 6d 3b 0d 0a 20 20 63 6f 6c 6f 72 3a 20 23 tom;.. color: #
3070: 30 30 30 66 36 61 3b 0d 0a 20 20 66 6f 6e 74 2d 000f6a;.. font-
3080: 73 69 7a 65 3a 20 30 2e 38 65 6d 3b 0d 0a 7d 0d size: 0.8em;..}.
3090: 0a 0d 0a 2f 2a 20 54 68 65 20 68 65 61 64 65 72 .../* The header
30a0: 20 61 63 72 6f 73 73 20 74 68 65 20 74 6f 70 20 across the top
30b0: 6f 66 20 74 68 65 20 70 61 67 65 20 2a 2f 0d 0a of the page */..
30c0: 64 69 76 2e 68 65 61 64 65 72 20 7b 0d 0a 20 20 div.header {..
30d0: 64 69 73 70 6c 61 79 3a 20 74 61 62 6c 65 3b 0d display: table;.
30e0: 0a 20 20 77 69 64 74 68 3a 20 31 30 30 25 3b 0d . width: 100%;.
30f0: 0a 20 20 74 65 78 74 2d 61 6c 69 67 6e 3a 20 63 . text-align: c
3100: 65 6e 74 65 72 3b 0d 0a 7d 0d 0a 0d 0a 2f 2a 20 enter;..}..../*
3110: 54 68 65 20 6d 61 69 6e 20 6d 65 6e 75 20 62 61 The main menu ba
3120: 72 20 74 68 61 74 20 61 70 70 65 61 72 73 20 61 r that appears a
3130: 74 20 74 68 65 20 74 6f 70 20 6f 66 20 74 68 65 t the top of the
3140: 20 70 61 67 65 20 62 65 6e 65 61 74 68 0d 0a 2a page beneath..*
3150: 2a 20 74 68 65 20 68 65 61 64 65 72 20 2a 2f 0d * the header */.
3160: 0a 64 69 76 2e 6d 61 69 6e 6d 65 6e 75 20 7b 0d .div.mainmenu {.
3170: 0a 20 20 70 61 64 64 69 6e 67 3a 20 32 70 78 20 . padding: 2px
3180: 35 70 78 20 32 70 78 20 35 70 78 3b 0d 0a 20 20 5px 2px 5px;..
3190: 66 6f 6e 74 2d 73 69 7a 65 3a 20 30 2e 39 65 6d font-size: 0.9em
31a0: 3b 0d 0a 20 20 74 65 78 74 2d 61 6c 69 67 6e 3a ;.. text-align:
31b0: 20 63 65 6e 74 65 72 3b 0d 0a 20 20 6c 65 74 74 center;.. lett
31c0: 65 72 2d 73 70 61 63 69 6e 67 3a 20 31 70 78 3b er-spacing: 1px;
31d0: 0d 0a 20 20 62 61 63 6b 67 72 6f 75 6e 64 2d 63 .. background-c
31e0: 6f 6c 6f 72 3a 20 23 65 33 65 33 65 33 3b 0d 0a olor: #e3e3e3;..
31f0: 20 20 63 6f 6c 6f 72 3a 20 23 30 30 30 66 36 61 color: #000f6a
3200: 3b 0d 0a 20 20 62 6f 72 64 65 72 3a 20 31 70 78 ;.. border: 1px
3210: 20 69 6e 73 65 74 20 62 6c 61 63 6b 3b 0d 0a 7d inset black;..}
3220: 0d 0a 0d 0a 2f 2a 20 54 68 65 20 73 75 62 6d 65 ..../* The subme
3230: 6e 75 20 62 61 72 20 74 68 61 74 20 2a 73 6f 6d nu bar that *som
3240: 65 74 69 6d 65 73 2a 20 61 70 70 65 61 72 73 20 etimes* appears
3250: 62 65 6c 6f 77 20 74 68 65 20 6d 61 69 6e 20 6d below the main m
3260: 65 6e 75 20 2a 2f 0d 0a 64 69 76 2e 73 75 62 6d enu */..div.subm
3270: 65 6e 75 20 7b 0d 0a 20 20 70 61 64 64 69 6e 67 enu {.. padding
3280: 3a 20 32 70 78 20 35 70 78 20 32 70 78 20 35 70 : 2px 5px 2px 5p
3290: 78 3b 0d 0a 20 20 66 6f 6e 74 2d 73 69 7a 65 3a x;.. font-size:
32a0: 20 30 2e 39 65 6d 3b 0d 0a 20 20 74 65 78 74 2d 0.9em;.. text-
32b0: 61 6c 69 67 6e 3a 20 63 65 6e 74 65 72 3b 0d 0a align: center;..
32c0: 20 20 62 61 63 6b 67 72 6f 75 6e 64 2d 63 6f 6c background-col
32d0: 6f 72 3a 20 23 65 33 65 33 65 33 3b 0d 0a 20 20 or: #e3e3e3;..
32e0: 63 6f 6c 6f 72 3a 20 23 30 30 30 66 36 61 3b 0d color: #000f6a;.
32f0: 0a 7d 0d 0a 64 69 76 2e 6d 61 69 6e 6d 65 6e 75 .}..div.mainmenu
3300: 20 61 2c 20 64 69 76 2e 6d 61 69 6e 6d 65 6e 75 a, div.mainmenu
3310: 20 61 3a 76 69 73 69 74 65 64 2c 20 64 69 76 2e a:visited, div.
3320: 73 75 62 6d 65 6e 75 20 61 2c 20 64 69 76 2e 73 submenu a, div.s
3330: 75 62 6d 65 6e 75 20 61 3a 76 69 73 69 74 65 64 ubmenu a:visited
3340: 20 7b 0d 0a 20 20 70 61 64 64 69 6e 67 3a 20 32 {.. padding: 2
3350: 70 78 20 31 30 70 78 20 32 70 78 20 31 30 70 78 px 10px 2px 10px
3360: 3b 0d 0a 20 20 63 6f 6c 6f 72 3a 20 23 30 30 30 ;.. color: #000
3370: 66 36 61 3b 0d 0a 20 20 62 61 63 6b 67 72 6f 75 f6a;.. backgrou
3380: 6e 64 2d 63 6f 6c 6f 72 3a 20 23 65 33 65 33 65 nd-color: #e3e3e
3390: 33 3b 0d 0a 20 20 74 65 78 74 2d 64 65 63 6f 72 3;.. text-decor
33a0: 61 74 69 6f 6e 3a 20 6e 6f 6e 65 3b 0d 0a 7d 0d ation: none;..}.
33b0: 0a 64 69 76 2e 6d 61 69 6e 6d 65 6e 75 20 61 3a .div.mainmenu a:
33c0: 68 6f 76 65 72 2c 20 64 69 76 2e 73 75 62 6d 65 hover, div.subme
33d0: 6e 75 20 61 3a 68 6f 76 65 72 20 7b 0d 0a 20 20 nu a:hover {..
33e0: 63 6f 6c 6f 72 3a 20 23 65 33 65 33 65 33 3b 0d color: #e3e3e3;.
33f0: 0a 20 20 62 61 63 6b 67 72 6f 75 6e 64 2d 63 6f . background-co
3400: 6c 6f 72 3a 20 23 30 30 30 66 36 61 3b 0d 0a 7d lor: #000f6a;..}
3410: 0d 0a 0d 0a 2f 2a 20 41 6c 6c 20 70 61 67 65 20 ..../* All page
3420: 63 6f 6e 74 65 6e 74 20 66 72 6f 6d 20 74 68 65 content from the
3430: 20 62 6f 74 74 6f 6d 20 6f 66 20 74 68 65 20 6d bottom of the m
3440: 65 6e 75 20 6f 72 20 73 75 62 6d 65 6e 75 20 64 enu or submenu d
3450: 6f 77 6e 20 74 6f 0d 0a 2a 2a 20 74 68 65 20 66 own to..** the f
3460: 6f 6f 74 65 72 20 2a 2f 0d 0a 64 69 76 2e 63 6f ooter */..div.co
3470: 6e 74 65 6e 74 20 7b 0d 0a 20 20 70 61 64 64 69 ntent {.. paddi
3480: 6e 67 3a 20 30 65 78 20 31 65 78 20 30 65 78 20 ng: 0ex 1ex 0ex
3490: 32 65 78 3b 0d 0a 7d 0d 0a 0d 0a 2f 2a 20 53 6f 2ex;..}..../* So
34a0: 6d 65 20 70 61 67 65 73 20 68 61 76 65 20 73 65 me pages have se
34b0: 63 74 69 6f 6e 20 64 69 76 69 64 65 72 73 20 2a ction dividers *
34c0: 2f 0d 0a 64 69 76 2e 73 65 63 74 69 6f 6e 20 7b /..div.section {
34d0: 0d 0a 20 20 6d 61 72 67 69 6e 2d 62 6f 74 74 6f .. margin-botto
34e0: 6d 3a 20 30 70 78 3b 0d 0a 20 20 6d 61 72 67 69 m: 0px;.. margi
34f0: 6e 2d 74 6f 70 3a 20 31 65 6d 3b 0d 0a 20 20 70 n-top: 1em;.. p
3500: 61 64 64 69 6e 67 3a 20 31 70 78 20 31 70 78 20 adding: 1px 1px
3510: 31 70 78 20 31 70 78 3b 0d 0a 20 20 66 6f 6e 74 1px 1px;.. font
3520: 2d 73 69 7a 65 3a 20 31 2e 32 65 6d 3b 0d 0a 20 -size: 1.2em;..
3530: 20 66 6f 6e 74 2d 77 65 69 67 68 74 3a 20 62 6f font-weight: bo
3540: 6c 64 3b 0d 0a 20 20 62 61 63 6b 67 72 6f 75 6e ld;.. backgroun
3550: 64 2d 63 6f 6c 6f 72 3a 20 23 65 33 65 33 65 33 d-color: #e3e3e3
3560: 3b 0d 0a 20 20 63 6f 6c 6f 72 3a 20 23 30 30 30 ;.. color: #000
3570: 66 36 61 3b 0d 0a 7d 0d 0a 0d 0a 2f 2a 20 54 68 f6a;..}..../* Th
3580: 65 20 22 44 61 74 65 22 20 74 68 61 74 20 6f 63 e "Date" that oc
3590: 63 75 72 73 20 6f 6e 20 74 68 65 20 6c 65 66 74 curs on the left
35a0: 20 68 61 6e 64 20 73 69 64 65 20 6f 66 20 74 69 hand side of ti
35b0: 6d 65 6c 69 6e 65 73 20 2a 2f 0d 0a 64 69 76 2e melines */..div.
35c0: 64 69 76 69 64 65 72 20 7b 0d 0a 20 20 62 61 63 divider {.. bac
35d0: 6b 67 72 6f 75 6e 64 2d 63 6f 6c 6f 72 3a 20 23 kground-color: #
35e0: 65 33 65 33 65 33 3b 0d 0a 20 20 63 6f 6c 6f 72 e3e3e3;.. color
35f0: 3a 20 23 30 30 30 66 36 61 3b 0d 0a 20 20 62 6f : #000f6a;.. bo
3600: 72 64 65 72 3a 20 31 70 78 20 23 62 62 62 62 66 rder: 1px #bbbbf
3610: 66 20 73 6f 6c 69 64 3b 0d 0a 20 20 66 6f 6e 74 f solid;.. font
3620: 2d 73 69 7a 65 3a 20 31 65 6d 3b 20 66 6f 6e 74 -size: 1em; font
3630: 2d 77 65 69 67 68 74 3a 20 6e 6f 72 6d 61 6c 3b -weight: normal;
3640: 0d 0a 20 20 70 61 64 64 69 6e 67 3a 20 2e 32 35 .. padding: .25
3650: 65 6d 3b 0d 0a 20 20 6d 61 72 67 69 6e 3a 20 2e em;.. margin: .
3660: 32 65 6d 20 30 20 2e 32 65 6d 20 30 3b 0d 0a 20 2em 0 .2em 0;..
3670: 20 66 6c 6f 61 74 3a 20 6c 65 66 74 3b 0d 0a 20 float: left;..
3680: 20 63 6c 65 61 72 3a 20 6c 65 66 74 3b 0d 0a 7d clear: left;..}
3690: 0d 0a 0d 0a 2f 2a 20 54 68 65 20 66 6f 6f 74 65 ..../* The foote
36a0: 72 20 61 74 20 74 68 65 20 76 65 72 79 20 62 6f r at the very bo
36b0: 74 74 6f 6d 20 6f 66 20 74 68 65 20 70 61 67 65 ttom of the page
36c0: 20 2a 2f 0d 0a 64 69 76 2e 66 6f 6f 74 65 72 20 */..div.footer
36d0: 7b 0d 0a 20 20 66 6f 6e 74 2d 73 69 7a 65 3a 20 {.. font-size:
36e0: 30 2e 38 65 6d 3b 0d 0a 20 20 70 61 64 64 69 6e 0.8em;.. paddin
36f0: 67 3a 20 32 70 78 20 35 70 78 20 32 70 78 20 35 g: 2px 5px 2px 5
3700: 70 78 3b 0d 0a 20 20 74 65 78 74 2d 61 6c 69 67 px;.. text-alig
3710: 6e 3a 20 63 65 6e 74 65 72 3b 0d 0a 20 20 6c 65 n: center;.. le
3720: 74 74 65 72 2d 73 70 61 63 69 6e 67 3a 20 31 70 tter-spacing: 1p
3730: 78 3b 0d 0a 20 20 62 61 63 6b 67 72 6f 75 6e 64 x;.. background
3740: 2d 63 6f 6c 6f 72 3a 20 23 65 33 65 33 65 33 3b -color: #e3e3e3;
3750: 0d 0a 20 20 63 6f 6c 6f 72 3a 20 23 30 30 30 66 .. color: #000f
3760: 36 61 3b 0d 0a 20 20 62 6f 72 64 65 72 3a 20 31 6a;.. border: 1
3770: 70 78 20 69 6e 73 65 74 20 62 6c 61 63 6b 3b 0d px inset black;.
3780: 0a 7d 0d 0a 0d 0a 2f 2a 20 4d 61 6b 65 20 74 68 .}..../* Make th
3790: 65 20 6c 69 6e 6b 73 20 69 6e 20 74 68 65 20 66 e links in the f
37a0: 6f 6f 74 65 72 20 6c 65 73 73 20 75 67 6c 79 2e ooter less ugly.
37b0: 2e 2e 20 2a 2f 0d 0a 64 69 76 2e 66 6f 6f 74 65 .. */..div.foote
37c0: 72 20 61 20 7b 20 63 6f 6c 6f 72 3a 20 23 30 30 r a { color: #00
37d0: 30 66 36 61 3b 20 7d 0d 0a 64 69 76 2e 66 6f 6f 0f6a; }..div.foo
37e0: 74 65 72 20 61 3a 6c 69 6e 6b 20 7b 20 63 6f 6c ter a:link { col
37f0: 6f 72 3a 20 23 30 30 30 66 36 61 3b 20 7d 0d 0a or: #000f6a; }..
3800: 64 69 76 2e 66 6f 6f 74 65 72 20 61 3a 76 69 73 div.footer a:vis
3810: 69 74 65 64 20 7b 20 63 6f 6c 6f 72 3a 20 23 30 ited { color: #0
3820: 30 30 66 36 61 3b 20 7d 0d 0a 64 69 76 2e 66 6f 00f6a; }..div.fo
3830: 6f 74 65 72 20 61 3a 68 6f 76 65 72 20 7b 20 62 oter a:hover { b
3840: 61 63 6b 67 72 6f 75 6e 64 2d 63 6f 6c 6f 72 3a ackground-color:
3850: 20 23 30 30 30 66 36 61 3b 20 63 6f 6c 6f 72 3a #000f6a; color:
3860: 20 23 65 33 65 33 65 33 3b 20 7d 0d 0a 0d 0a 2f #e3e3e3; }..../
3870: 2a 20 76 65 72 62 61 74 69 6d 20 62 6c 6f 63 6b * verbatim block
3880: 73 20 2a 2f 0d 0a 70 72 65 2e 76 65 72 62 61 74 s */..pre.verbat
3890: 69 6d 20 7b 0d 0a 20 20 20 62 61 63 6b 67 72 6f im {.. backgro
38a0: 75 6e 64 2d 63 6f 6c 6f 72 3a 20 23 66 35 66 35 und-color: #f5f5
38b0: 66 35 3b 0d 0a 20 20 20 70 61 64 64 69 6e 67 3a f5;.. padding:
38c0: 20 30 2e 35 65 6d 3b 0d 0a 7d 0d 0a 0d 0a 2f 2a 0.5em;..}..../*
38d0: 20 54 68 65 20 6c 61 62 65 6c 2f 76 61 6c 75 65 The label/value
38e0: 20 70 61 69 72 73 20 6f 6e 20 28 66 6f 72 20 65 pairs on (for e
38f0: 78 61 6d 70 6c 65 29 20 74 68 65 20 76 69 6e 66 xample) the vinf
3900: 6f 20 70 61 67 65 20 2a 2f 0d 0a 74 61 62 6c 65 o page */..table
3910: 2e 6c 61 62 65 6c 2d 76 61 6c 75 65 20 74 68 20 .label-value th
3920: 7b 0d 0a 20 20 76 65 72 74 69 63 61 6c 2d 61 6c {.. vertical-al
3930: 69 67 6e 3a 20 74 6f 70 3b 0d 0a 20 20 74 65 78 ign: top;.. tex
3940: 74 2d 61 6c 69 67 6e 3a 20 72 69 67 68 74 3b 0d t-align: right;.
3950: 0a 20 20 70 61 64 64 69 6e 67 3a 20 30 2e 32 65 . padding: 0.2e
3960: 78 20 32 65 78 3b 0d 0a 7d 0d 0a 0d 0a 2f 2a 20 x 2ex;..}..../*
3970: 46 6f 72 20 6d 61 72 6b 69 6e 67 20 69 6d 70 6f For marking impo
3980: 72 74 61 6e 74 20 55 49 20 65 6c 65 6d 65 6e 74 rtant UI element
3990: 73 20 77 68 69 63 68 20 73 68 6f 75 6c 64 6e 27 s which shouldn'
39a0: 74 20 62 65 0d 0a 20 20 20 6c 69 67 68 74 6c 79 t be.. lightly
39b0: 20 64 69 73 6d 69 73 73 65 64 2e 20 49 20 6d 61 dismissed. I ma
39c0: 69 6e 6c 79 20 75 73 65 20 69 74 20 74 6f 20 6d inly use it to m
39d0: 61 72 6b 20 22 6e 6f 74 20 79 65 74 0d 0a 20 20 ark "not yet..
39e0: 20 69 6d 70 6c 65 6d 65 6e 74 65 64 22 20 70 61 implemented" pa
39f0: 72 74 73 20 6f 66 20 61 20 70 61 67 65 2e 20 57 rts of a page. W
3a00: 68 65 74 68 65 72 20 6f 72 20 6e 6f 74 20 74 6f hether or not to
3a10: 20 68 61 76 65 0d 0a 20 20 20 61 20 27 62 6f 72 have.. a 'bor
3a20: 64 65 72 27 20 61 74 74 72 69 62 75 74 65 20 73 der' attribute s
3a30: 65 74 20 69 73 20 61 72 67 75 61 62 6c 65 2e 20 et is arguable.
3a40: 2a 2f 0d 0a 2e 61 63 68 74 75 6e 67 20 7b 0d 0a */...achtung {..
3a50: 20 20 63 6f 6c 6f 72 3a 20 23 66 66 30 30 30 30 color: #ff0000
3a60: 3b 0d 0a 20 20 62 61 63 6b 67 72 6f 75 6e 64 3a ;.. background:
3a70: 20 23 66 66 66 66 30 30 3b 0d 0a 20 20 62 6f 72 #ffff00;.. bor
3a80: 64 65 72 3a 20 31 70 78 20 73 6f 6c 69 64 20 23 der: 1px solid #
3a90: 66 66 30 30 30 30 3b 0d 0a 7d 0d 0a 0d 0a 74 61 ff0000;..}....ta
3aa0: 62 6c 65 2e 66 6f 73 73 69 6c 5f 64 62 5f 67 65 ble.fossil_db_ge
3ab0: 6e 65 72 69 63 5f 71 75 65 72 79 5f 76 69 65 77 neric_query_view
3ac0: 20 7b 0d 0a 20 20 62 6f 72 64 65 72 2d 73 70 61 {.. border-spa
3ad0: 63 69 6e 67 3a 20 30 70 78 3b 0d 0a 20 20 62 6f cing: 0px;.. bo
3ae0: 72 64 65 72 3a 20 31 70 78 20 73 6f 6c 69 64 20 rder: 1px solid
3af0: 62 6c 61 63 6b 3b 0d 0a 7d 0d 0a 74 61 62 6c 65 black;..}..table
3b00: 2e 66 6f 73 73 69 6c 5f 64 62 5f 67 65 6e 65 72 .fossil_db_gener
3b10: 69 63 5f 71 75 65 72 79 5f 76 69 65 77 20 74 64 ic_query_view td
3b20: 20 7b 0d 0a 20 20 70 61 64 64 69 6e 67 3a 20 32 {.. padding: 2
3b30: 70 78 20 31 65 6d 20 32 70 78 20 31 65 6d 3b 0d px 1em 2px 1em;.
3b40: 0a 7d 0d 0a 74 61 62 6c 65 2e 66 6f 73 73 69 6c .}..table.fossil
3b50: 5f 64 62 5f 67 65 6e 65 72 69 63 5f 71 75 65 72 _db_generic_quer
3b60: 79 5f 76 69 65 77 20 74 72 20 7b 0d 0a 7d 0d 0a y_view tr {..}..
3b70: 74 61 62 6c 65 2e 66 6f 73 73 69 6c 5f 64 62 5f table.fossil_db_
3b80: 67 65 6e 65 72 69 63 5f 71 75 65 72 79 5f 76 69 generic_query_vi
3b90: 65 77 20 74 72 2e 65 76 65 6e 20 7b 0d 0a 20 20 ew tr.even {..
3ba0: 62 61 63 6b 67 72 6f 75 6e 64 3a 20 23 66 66 66 background: #fff
3bb0: 66 66 66 3b 0d 0a 7d 0d 0a 74 61 62 6c 65 2e 66 fff;..}..table.f
3bc0: 6f 73 73 69 6c 5f 64 62 5f 67 65 6e 65 72 69 63 ossil_db_generic
3bd0: 5f 71 75 65 72 79 5f 76 69 65 77 20 74 72 2e 6f _query_view tr.o
3be0: 64 64 20 7b 0d 0a 20 20 62 61 63 6b 67 72 6f 75 dd {.. backgrou
3bf0: 6e 64 3a 20 23 65 35 65 35 65 35 3b 0d 0a 7d 0d nd: #e5e5e5;..}.
3c00: 0a 74 61 62 6c 65 2e 66 6f 73 73 69 6c 5f 64 62 .table.fossil_db
3c10: 5f 67 65 6e 65 72 69 63 5f 71 75 65 72 79 5f 76 _generic_query_v
3c20: 69 65 77 20 74 72 2e 68 65 61 64 65 72 20 7b 0d iew tr.header {.
3c30: 0a 20 20 62 61 63 6b 67 72 6f 75 6e 64 3a 20 23 . background: #
3c40: 35 35 38 31 39 35 3b 0d 0a 20 20 66 6f 6e 74 2d 558195;.. font-
3c50: 73 69 7a 65 3a 20 31 2e 35 65 6d 3b 0d 0a 20 20 size: 1.5em;..
3c60: 63 6f 6c 6f 72 3a 20 23 66 66 66 66 66 66 3b 0d color: #ffffff;.
3c70: 0a 7d 0d 0a 3c 2f 70 72 65 3e 0d 0a 3c 2f 6e 6f .}..</pre>..</no
3c80: 77 69 6b 69 3e 0d 0a 3c 68 32 3e 3c 61 20 6e 61 wiki>..<h2><a na
3c90: 6d 65 3d 22 73 6f 75 72 63 65 2d 68 69 6c 69 67 me="source-hilig
3ca0: 68 74 22 3e 53 6f 75 72 63 65 20 68 69 67 68 6c ht">Source highl
3cb0: 69 67 68 74 69 6e 67 3c 2f 61 3e 3c 2f 68 32 3e ighting</a></h2>
3cc0: 0d 0a 3c 68 33 3e 4d 6f 74 69 76 61 74 69 6f 6e ..<h3>Motivation
3cd0: 3c 2f 68 33 3e 0d 0a 20 20 2a 20 20 59 6f 75 20 </h3>.. * You
3ce0: 77 61 6e 74 20 74 6f 20 68 61 76 65 20 73 6f 75 want to have sou
3cf0: 72 63 65 20 63 6f 64 65 20 68 69 67 68 6c 69 67 rce code highlig
3d00: 68 74 69 6e 67 20 66 6f 72 20 74 68 65 20 66 69 hting for the fi
3d10: 6c 65 73 20 69 6e 20 79 6f 75 72 20 72 65 70 6f les in your repo
3d20: 73 69 74 6f 72 79 0d 0a 0d 0a 3c 68 33 3e 50 72 sitory....<h3>Pr
3d30: 6f 62 6c 65 6d 3c 2f 68 33 3e 0d 0a 54 68 65 20 oblem</h3>..The
3d40: 6d 61 69 6e 20 70 75 72 70 6f 73 65 20 6f 66 20 main purpose of
3d50: 46 6f 73 73 69 6c 20 69 73 20 74 6f 20 64 6f 20 Fossil is to do
3d60: 76 65 72 73 69 6f 6e 69 6e 67 20 74 68 65 20 73 versioning the s
3d70: 6f 75 72 63 65 20 63 6f 64 65 2e 20 41 6c 74 68 ource code. Alth
3d80: 6f 75 67 68 20 69 74 20 70 72 6f 76 69 64 65 73 ough it provides
3d90: 20 61 20 73 74 61 6e 64 61 6c 6f 6e 65 20 73 65 a standalone se
3da0: 72 76 65 72 20 61 6e 64 20 6c 65 74 73 20 79 6f rver and lets yo
3db0: 75 20 6e 61 76 69 67 61 74 65 20 74 68 72 6f 75 u navigate throu
3dc0: 67 68 20 74 68 65 20 72 65 70 6f 73 69 74 6f 72 gh the repositor
3dd0: 79 20 66 69 6c 65 73 20 61 64 64 69 74 69 6f 6e y files addition
3de0: 61 6c 20 66 65 61 74 75 72 65 73 20 6c 69 6b 65 al features like
3df0: 20 73 6f 75 72 63 65 20 63 6f 64 65 20 68 69 67 source code hig
3e00: 68 6c 69 67 68 74 69 6e 67 20 66 72 6f 6d 20 6d hlighting from m
3e10: 79 20 70 65 72 73 70 65 63 74 69 76 65 20 28 49 y perspective (I
3e20: 20 61 6d 20 6e 6f 74 20 61 20 64 65 76 65 6c 6f am not a develo
3e30: 70 65 72 20 6f 66 20 46 6f 73 73 69 6c 29 20 69 per of Fossil) i
3e40: 73 20 6f 75 74 20 6f 66 20 73 63 6f 70 65 20 66 s out of scope f
3e50: 6f 72 20 61 6e 20 53 43 4d 2e 20 4a 75 73 74 20 or an SCM. Just
3e60: 6b 65 65 70 20 74 68 65 20 55 6e 69 78 20 70 72 keep the Unix pr
3e70: 69 6e 63 69 70 6c 65 3a 20 73 6d 61 6c 6c 20 6c inciple: small l
3e80: 69 74 74 6c 65 20 70 72 6f 67 72 61 6d 73 20 74 ittle programs t
3e90: 68 61 74 20 64 6f 20 74 68 65 69 72 20 74 61 73 hat do their tas
3ea0: 6b 20 61 6e 64 20 64 6f 20 69 74 20 77 65 6c 6c k and do it well
3eb0: 2e 0d 0a 0d 0a 48 6f 77 65 76 65 72 20 74 6f 20 .....However to
3ec0: 68 61 76 65 20 61 20 73 6f 75 72 63 65 20 63 6f have a source co
3ed0: 64 65 20 68 69 67 68 6c 69 67 68 74 69 6e 67 20 de highlighting
3ee0: 69 6e 20 74 68 65 20 70 72 65 73 65 6e 74 65 64 in the presented
3ef0: 20 77 65 62 20 70 61 67 65 73 20 77 6f 75 6c 64 web pages would
3f00: 20 73 74 69 6c 6c 20 62 65 20 64 65 73 69 72 61 still be desira
3f10: 62 6c 65 2e 0d 0a 0d 0a 3c 68 33 3e 53 6f 6c 75 ble.....<h3>Solu
3f20: 74 69 6f 6e 3c 2f 68 33 3e 0d 0a 54 68 65 72 65 tion</h3>..There
3f30: 20 61 72 65 20 74 77 6f 20 73 63 65 6e 61 72 69 are two scenari
3f40: 6f 73 20 68 6f 77 20 74 6f 20 69 6d 70 6c 65 6d os how to implem
3f50: 65 6e 74 20 73 75 63 68 20 61 20 66 65 61 74 75 ent such a featu
3f60: 72 65 3a 0d 0a 20 20 20 2a 20 20 46 6f 73 73 69 re:.. * Fossi
3f70: 6c 20 70 69 70 65 73 20 74 68 65 20 73 6f 75 72 l pipes the sour
3f80: 63 65 20 63 6f 64 65 20 74 68 72 6f 75 67 68 20 ce code through
3f90: 61 20 66 69 6c 74 65 72 20 62 65 66 6f 72 65 20 a filter before
3fa0: 73 65 6e 64 69 6e 67 20 69 74 20 74 6f 20 74 68 sending it to th
3fb0: 65 20 62 72 6f 77 73 65 72 2e 20 54 68 65 20 66 e browser. The f
3fc0: 69 6c 74 65 72 20 63 6f 75 6c 64 20 62 65 20 64 ilter could be d
3fd0: 65 66 69 6e 65 64 20 61 73 20 61 20 63 6f 6e 66 efined as a conf
3fe0: 69 67 75 72 61 74 69 6f 6e 20 6f 70 74 69 6f 6e iguration option
3ff0: 20 74 6f 20 46 6f 73 73 69 6c 2e 20 4f 6e 65 20 to Fossil. One
4000: 73 6f 6c 75 74 69 6f 6e 20 66 6f 72 20 74 68 69 solution for thi
4010: 73 20 6d 69 67 68 74 20 62 65 20 74 68 65 20 3c s might be the <
4020: 61 20 68 72 65 66 3d 22 68 74 74 70 3a 2f 2f 77 a href="http://w
4030: 77 77 2e 67 6e 75 2e 6f 72 67 2f 73 6f 66 74 77 ww.gnu.org/softw
4040: 61 72 65 2f 73 72 63 2d 68 69 67 68 6c 69 74 65 are/src-highlite
4050: 22 3e 47 4e 55 20 53 6f 75 72 63 65 20 63 6f 64 ">GNU Source cod
4060: 65 20 48 69 67 68 6c 69 67 68 74 69 6e 67 3c 2f e Highlighting</
4070: 61 3e 20 70 72 6f 67 72 61 6d 2e 0d 0a 20 20 20 a> program...
4080: 2a 20 20 55 73 65 20 61 20 4a 61 76 61 73 63 72 * Use a Javascr
4090: 69 70 74 20 6c 69 62 72 61 72 79 20 74 68 61 74 ipt library that
40a0: 20 72 65 6e 64 65 72 73 20 74 68 65 20 63 6f 64 renders the cod
40b0: 65 20 77 69 74 68 69 6e 20 79 6f 75 72 20 62 72 e within your br
40c0: 6f 77 73 65 72 2e 20 4f 6e 65 20 73 6f 6c 75 74 owser. One solut
40d0: 69 6f 6e 20 66 6f 72 20 74 68 69 73 20 6d 69 67 ion for this mig
40e0: 68 74 20 62 65 20 3c 61 20 68 72 65 66 3d 22 68 ht be <a href="h
40f0: 74 74 70 3a 2f 2f 63 6f 64 65 2e 67 6f 6f 67 6c ttp://code.googl
4100: 65 2e 63 6f 6d 2f 70 2f 73 79 6e 74 61 78 68 69 e.com/p/syntaxhi
4110: 67 68 6c 69 67 68 74 65 72 22 3e 47 6f 6f 67 6c ghlighter">Googl
4120: 65 20 53 79 6e 74 61 78 20 48 69 67 68 6c 69 67 e Syntax Highlig
4130: 68 74 65 72 3c 2f 61 3e 0d 0a 0d 0a 49 20 65 73 hter</a>....I es
4140: 74 69 6d 61 74 65 20 74 68 61 74 20 74 68 65 20 timate that the
4150: 3c 69 3e 70 69 70 65 3c 2f 69 3e 20 73 6f 6c 75 <i>pipe</i> solu
4160: 74 69 6f 6e 20 6e 65 65 64 73 20 73 6f 6d 65 20 tion needs some
4170: 6d 6f 72 65 20 77 6f 72 6b 2f 20 63 6f 64 65 20 more work/ code
4180: 63 68 61 6e 67 65 73 2e 20 54 68 75 73 20 49 20 changes. Thus I
4190: 61 6d 20 73 6f 6c 65 6c 79 20 6c 6f 6f 6b 69 6e am solely lookin
41a0: 67 20 61 74 20 74 68 65 20 4a 61 76 61 73 63 72 g at the Javascr
41b0: 69 70 74 20 73 6f 6c 75 74 69 6f 6e 2e 0d 0a 0d ipt solution....
41c0: 0a 54 68 65 20 53 79 6e 74 61 78 48 69 67 68 6c .The SyntaxHighl
41d0: 69 67 68 74 65 72 20 69 73 20 61 20 6c 69 62 72 ighter is a libr
41e0: 61 72 79 20 6f 66 20 73 6f 6d 65 20 4a 61 76 61 ary of some Java
41f0: 73 63 72 69 70 74 20 66 69 6c 65 73 2c 20 61 20 script files, a
4200: 6c 69 74 74 6c 65 20 46 6c 61 73 68 20 61 70 70 little Flash app
4210: 6c 69 63 61 74 69 6f 6e 20 61 6e 64 20 61 20 43 lication and a C
4220: 53 53 20 66 69 6c 65 2e 20 54 68 65 20 46 6c 61 SS file. The Fla
4230: 73 68 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 69 sh application i
4240: 73 20 66 6f 72 20 63 6f 70 79 69 6e 67 20 74 6f s for copying to
4250: 20 63 6c 69 70 62 6f 61 72 64 2c 20 70 72 69 6e clipboard, prin
4260: 74 20 61 6e 64 20 76 69 65 77 20 73 6f 75 72 63 t and view sourc
4270: 65 2e 20 59 6f 75 20 68 61 76 65 20 74 68 65 20 e. You have the
4280: 6f 70 74 69 6f 6e 20 74 6f 20 69 6e 63 6c 75 64 option to includ
4290: 65 20 61 6c 6c 20 74 68 65 20 66 69 6c 65 73 20 e all the files
42a0: 69 6e 74 6f 20 79 6f 75 72 20 72 65 70 6f 73 69 into your reposi
42b0: 74 6f 72 79 20 6f 72 20 75 73 65 20 74 68 65 20 tory or use the
42c0: 66 69 6c 65 73 20 68 6f 73 74 65 64 20 61 74 20 files hosted at
42d0: 47 6f 6f 67 6c 65 2e 20 54 68 65 20 6c 61 74 74 Google. The latt
42e0: 65 72 20 6d 61 79 20 6f 6e 6c 79 20 62 65 20 61 er may only be a
42f0: 6e 20 6f 70 74 69 6f 6e 20 69 66 20 79 6f 75 20 n option if you
4300: 61 72 65 20 63 6f 6e 6e 65 63 74 65 64 20 74 6f are connected to
4310: 20 69 6e 74 65 72 6e 65 74 20 61 6c 6c 20 74 68 internet all th
4320: 65 20 74 69 6d 65 2e 0d 0a 0d 0a 46 6f 72 20 73 e time.....For s
4330: 79 6e 74 61 78 20 68 69 67 68 6c 69 67 68 74 69 yntax highlighti
4340: 6e 67 20 74 6f 20 77 6f 72 6b 20 74 68 65 20 48 ng to work the H
4350: 65 61 64 65 72 20 61 6e 64 20 46 6f 6f 74 65 72 eader and Footer
4360: 20 74 65 6d 70 6c 61 74 65 73 20 6e 65 65 64 20 templates need
4370: 74 6f 20 62 65 20 6d 6f 64 69 66 69 65 64 20 61 to be modified a
4380: 6e 64 20 61 20 6c 69 74 74 6c 65 20 63 6f 64 65 nd a little code
4390: 20 63 68 61 6e 67 65 20 68 61 73 20 74 6f 20 62 change has to b
43a0: 65 20 61 70 70 6c 69 65 64 20 74 6f 20 74 68 65 e applied to the
43b0: 20 46 6f 73 73 69 6c 20 73 6f 75 72 63 65 73 2e Fossil sources.
43c0: 0d 0a 54 68 65 20 65 78 61 6d 70 6c 65 73 20 62 ..The examples b
43d0: 65 6c 6f 77 20 61 73 73 75 6d 65 20 79 6f 75 20 elow assume you
43e0: 68 61 76 65 20 61 64 64 65 64 20 74 68 65 20 73 have added the s
43f0: 79 6e 74 61 78 20 68 69 67 68 6c 69 67 68 74 69 yntax highlighti
4400: 6e 67 20 6c 69 62 72 61 72 79 20 74 6f 20 79 6f ng library to yo
4410: 75 72 20 72 65 70 6f 73 69 74 6f 72 79 20 69 6e ur repository in
4420: 74 6f 20 61 20 64 69 72 65 63 74 6f 72 79 20 77 to a directory w
4430: 77 77 2f 73 63 72 69 70 74 73 2e 0d 0a 3c 70 3e ww/scripts...<p>
4440: 0d 0a 3c 62 3e 48 65 61 64 65 72 3c 2f 62 3e 0d ..<b>Header</b>.
4450: 0a 3c 70 72 65 3e 0d 0a 26 6c 74 3b 68 74 6d 6c .<pre>..<html
4460: 26 67 74 3b 0d 0a 20 26 6c 74 3b 68 65 61 64 26 >.. <head&
4470: 67 74 3b 0d 0a 20 26 6c 74 3b 74 69 74 6c 65 26 gt;.. <title&
4480: 67 74 3b 24 26 6c 74 3b 70 72 6f 6a 65 63 74 5f gt;$<project_
4490: 6e 61 6d 65 26 67 74 3b 3a 20 24 26 6c 74 3b 74 name>: $<t
44a0: 69 74 6c 65 26 67 74 3b 26 6c 74 3b 2f 74 69 74 itle></tit
44b0: 6c 65 26 67 74 3b 0d 0a 20 26 6c 74 3b 6c 69 6e le>.. <lin
44c0: 6b 20 72 65 6c 3d 22 61 6c 74 65 72 6e 61 74 65 k rel="alternate
44d0: 22 20 74 79 70 65 3d 22 61 70 70 6c 69 63 61 74 " type="applicat
44e0: 69 6f 6e 2f 72 73 73 2b 78 6d 6c 22 20 74 69 74 ion/rss+xml" tit
44f0: 6c 65 3d 22 52 53 53 20 46 65 65 64 22 0d 0a 20 le="RSS Feed"..
4500: 20 20 20 20 20 20 68 72 65 66 3d 22 24 62 61 73 href="$bas
4510: 65 75 72 6c 2f 74 69 6d 65 6c 69 6e 65 2e 72 73 eurl/timeline.rs
4520: 73 22 26 67 74 3b 0d 0a 20 26 6c 74 3b 6c 69 6e s">.. <lin
4530: 6b 20 72 65 6c 3d 22 73 74 79 6c 65 73 68 65 65 k rel="styleshee
4540: 74 22 20 68 72 65 66 3d 22 24 62 61 73 65 75 72 t" href="$baseur
4550: 6c 2f 73 74 79 6c 65 2e 63 73 73 22 20 74 79 70 l/style.css" typ
4560: 65 3d 22 74 65 78 74 2f 63 73 73 22 0d 0a 20 20 e="text/css"..
4570: 20 20 20 20 20 6d 65 64 69 61 3d 22 73 63 72 65 media="scre
4580: 65 6e 22 26 67 74 3b 0d 0a 20 26 6c 74 3b 6c 69 en">.. <li
4590: 6e 6b 20 72 65 6c 3d 22 73 74 79 6c 65 73 68 65 nk rel="styleshe
45a0: 65 74 22 20 68 72 65 66 3d 22 24 62 61 73 65 75 et" href="$baseu
45b0: 72 6c 2f 64 6f 63 2f 74 69 70 2f 77 77 77 2f 53 rl/doc/tip/www/S
45c0: 79 6e 74 61 78 48 69 67 68 6c 69 67 68 74 65 72 yntaxHighlighter
45d0: 2e 63 73 73 22 20 74 79 70 65 3d 22 74 65 78 74 .css" type="text
45e0: 2f 63 73 73 22 0d 0a 20 20 20 20 20 20 20 6d 65 /css".. me
45f0: 64 69 61 3d 22 73 63 72 65 65 6e 22 26 67 74 3b dia="screen">
4600: 0d 0a 20 26 6c 74 3b 2f 68 65 61 64 26 67 74 3b .. </head>
4610: 0d 0a 0d 0a 2e 20 2e 20 2e 0d 0a 3c 2f 70 72 65 ..... . ...</pre
4620: 3e 0d 0a 3c 2f 70 3e 3c 70 3e 0d 0a 3c 62 3e 46 >..</p><p>..<b>F
4630: 6f 6f 74 65 72 3c 2f 62 3e 0d 0a 3c 70 72 65 3e ooter</b>..<pre>
4640: 0d 0a 26 6c 74 3b 2f 64 69 76 26 67 74 3b 0d 0a ..</div>..
4650: 26 6c 74 3b 64 69 76 20 63 6c 61 73 73 3d 22 66 <div class="f
4660: 6f 6f 74 65 72 22 26 67 74 3b 0d 0a 46 6f 73 73 ooter">..Foss
4670: 69 6c 20 76 65 72 73 69 6f 6e 20 24 6d 61 6e 69 il version $mani
4680: 66 65 73 74 5f 76 65 72 73 69 6f 6e 20 24 6d 61 fest_version $ma
4690: 6e 69 66 65 73 74 5f 64 61 74 65 0d 0a 26 67 74 nifest_date..>
46a0: 3b 2f 64 69 76 26 67 74 3b 0d 0a 26 6c 74 3b 73 ;/div>..<s
46b0: 63 72 69 70 74 20 6c 61 6e 67 75 61 67 65 3d 22 cript language="
46c0: 6a 61 76 61 73 63 72 69 70 74 22 20 73 72 63 3d javascript" src=
46d0: 22 24 62 61 73 65 75 72 6c 2f 64 6f 63 2f 74 69 "$baseurl/doc/ti
46e0: 70 2f 77 77 77 2f 73 63 72 69 70 74 73 2f 73 68 p/www/scripts/sh
46f0: 43 6f 72 65 2e 6a 73 22 26 67 74 3b 26 6c 74 3b Core.js"><
4700: 2f 73 63 72 69 70 74 26 67 74 3b 0d 0a 26 6c 74 /script>..<
4710: 3b 73 63 72 69 70 74 20 6c 61 6e 67 75 61 67 65 ;script language
4720: 3d 22 6a 61 76 61 73 63 72 69 70 74 22 20 73 72 ="javascript" sr
4730: 63 3d 22 24 62 61 73 65 75 72 6c 2f 64 6f 63 2f c="$baseurl/doc/
4740: 74 69 70 2f 77 77 77 2f 73 63 72 69 70 74 73 2f tip/www/scripts/
4750: 73 68 42 72 75 73 68 43 70 70 2e 6a 73 22 26 67 shBrushCpp.js"&g
4760: 74 3b 26 6c 74 3b 2f 73 63 72 69 70 74 26 67 74 t;</script>
4770: 3b 0d 0a 26 6c 74 3b 73 63 72 69 70 74 20 6c 61 ;..<script la
4780: 6e 67 75 61 67 65 3d 22 6a 61 76 61 73 63 72 69 nguage="javascri
4790: 70 74 22 26 67 74 3b 0d 0a 64 70 2e 53 79 6e 74 pt">..dp.Synt
47a0: 61 78 48 69 67 68 6c 69 67 68 74 65 72 2e 43 6c axHighlighter.Cl
47b0: 69 70 62 6f 61 72 64 53 77 66 20 3d 20 27 24 62 ipboardSwf = '$b
47c0: 61 73 65 75 72 6c 2f 64 6f 63 2f 74 69 70 2f 77 aseurl/doc/tip/w
47d0: 77 77 2f 73 63 72 69 70 74 73 2f 63 6c 69 70 62 ww/scripts/clipb
47e0: 6f 61 72 64 2e 73 77 66 27 3b 0d 0a 64 70 2e 53 oard.swf';..dp.S
47f0: 79 6e 74 61 78 48 69 67 68 6c 69 67 68 74 65 72 yntaxHighlighter
4800: 2e 48 69 67 68 6c 69 67 68 74 41 6c 6c 28 27 63 .HighlightAll('c
4810: 6f 64 65 27 29 3b 0d 0a 26 6c 74 3b 2f 73 63 72 ode');..</scr
4820: 69 70 74 26 67 74 3b 0d 0a 26 6c 74 3b 2f 62 6f ipt>..</bo
4830: 64 79 26 67 74 3b 26 6c 74 3b 2f 68 74 6d 6c 26 dy></html&
4840: 67 74 3b 0d 0a 3c 2f 70 72 65 3e 0d 0a 3c 2f 70 gt;..</pre>..</p
4850: 3e 3c 70 3e 0d 0a 3c 62 3e 46 6f 73 73 69 6c 2f ><p>..<b>Fossil/
4860: 73 72 63 2f 69 6e 66 6f 2e 63 3c 2f 62 3e 20 66 src/info.c</b> f
4870: 75 6e 63 74 69 6f 6e 20 61 72 74 69 66 61 63 74 unction artifact
4880: 5f 70 61 67 65 0d 0a 3c 70 72 65 3e 0d 0a 69 66 _page..<pre>..if
4890: 28 20 7a 4d 69 6d 65 3d 3d 30 20 29 7b 0d 0a 20 ( zMime==0 ){..
48a0: 20 20 20 40 20 26 6c 74 3b 70 72 65 20 6e 61 6d @ <pre nam
48b0: 65 3d 22 63 6f 64 65 22 20 63 6c 61 73 73 3d 22 e="code" class="
48c0: 63 22 26 67 74 3b 0d 0a 20 20 20 20 40 20 25 68 c">.. @ %h
48d0: 28 62 6c 6f 62 5f 73 74 72 28 26 63 6f 6e 74 65 (blob_str(&conte
48e0: 6e 74 29 29 0d 0a 20 20 20 20 40 20 26 6c 74 3b nt)).. @ <
48f0: 2f 70 72 65 26 67 74 3b 0d 0a 3c 2f 70 72 65 3e /pre>..</pre>
4900: 0d 0a 3c 2f 70 3e 0d 0a 3c 68 33 3e 44 69 73 63 ..</p>..<h3>Disc
4910: 75 73 73 69 6f 6e 3c 2f 68 33 3e 0d 0a 54 68 65 ussion</h3>..The
4920: 20 4a 61 76 61 73 63 72 69 70 74 20 73 6f 6c 75 Javascript solu
4930: 74 69 6f 6e 20 72 65 71 75 69 72 65 73 20 61 20 tion requires a
4940: 6d 69 6e 69 6d 75 6d 20 74 6f 20 62 65 20 66 75 minimum to be fu
4950: 6c 6c 79 20 73 75 70 70 6f 72 74 65 64 20 62 79 lly supported by
4960: 20 46 6f 73 73 69 6c 2e 20 4f 66 20 63 6f 75 72 Fossil. Of cour
4970: 73 65 20 6d 79 20 6c 69 74 74 65 20 63 68 61 6e se my litte chan
4980: 67 65 20 6f 6e 6c 79 20 61 70 70 6c 69 65 73 20 ge only applies
4990: 66 6f 72 20 43 2f 43 2b 2b 20 66 69 6c 65 73 2e for C/C++ files.
49a0: 20 42 75 74 20 6f 6e 6c 79 20 6c 69 74 74 6c 65 But only little
49b0: 20 6d 6f 72 65 20 77 6f 72 6b 20 6e 65 65 64 73 more work needs
49c0: 20 74 6f 20 62 65 20 64 6f 6e 65 20 74 6f 20 67 to be done to g
49d0: 65 74 20 74 68 65 20 65 78 74 65 6e 73 69 6f 6e et the extension
49e0: 20 6f 66 20 74 68 65 20 66 69 6c 65 20 61 20 67 of the file a g
49f0: 75 65 73 73 20 74 68 65 20 66 69 6c 65 20 74 79 uess the file ty
4a00: 70 65 2e 0d 0a 0d 0a 54 68 65 20 70 69 70 65 20 pe.....The pipe
4a10: 73 6f 6c 75 74 69 6f 6e 20 77 6f 75 6c 64 20 61 solution would a
4a20: 6c 73 6f 20 62 65 20 6e 69 63 65 20 62 75 74 20 lso be nice but
4a30: 77 6f 75 6c 64 20 70 72 6f 62 61 62 6c 79 20 6e would probably n
4a40: 65 65 64 20 73 6f 6d 65 20 6d 6f 72 65 20 77 6f eed some more wo
4a50: 72 6b 20 74 68 61 6e 20 74 68 69 73 20 6c 69 74 rk than this lit
4a60: 74 6c 65 20 70 61 74 63 68 2e 0d 0a 0a 5a 20 32 tle patch....Z 2
4a70: 65 66 30 34 65 31 61 65 39 64 35 63 31 62 39 34 ef04e1ae9d5c1b94
4a80: 39 62 66 38 33 30 32 64 61 39 65 33 35 38 32 0a 9bf8302da9e3582.