I wrote a patch to do simple searching on the source tree at a given check-in. Note: This is very minimalistic and has much room for improvement: 1) It just does a straight glob on the files. It does not differentiate between whole or partial words, and is always case sensitive. 2) Opening a file in the list does not mark the search terms. 3) The search box itself is not formatted in any way (CSS) 4) I experimented with creating a search index, and doing so would help solve problems 1&2, but this seems to work well enough for a start. I tested it on the Tcl repository (which is the largest fossil repository I am aware of) and got results in under a second on my 3 year-old laptop. Here is the patch: http://pastebin.com/571VmAuG
I also made a patch to allow multiple highlighting regions on an artifact page. I thought I would use it for marking the search results, but it didn't work out the way I thought. It still may be useful on it's own though. The syntax in the URL is e.g. `?ln=4-7|19|400-467|200-203`. I would have preferred to use ',' to separate groups, as it is more natural, but that would break backwards compatibility if anybody actually uses that syntax, which I don't think anyone does. Here is the patch: http://pastebin.com/2ugWvvTR I hope these help someone. Please feel free to fix. -- ˙uʍop-ǝpısdn sı ɹoʇıuoɯ ɹnoʎ 'sıɥʇ pɐǝɹ uɐɔ noʎ ɟı
_______________________________________________ fossil-users mailing list [email protected] http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

