This document explains how to set up the components required for fulltext searching in a Subversion repository: indexing server, post-commit hook and search gui.
Repos Search runs on Windows but the scripts examples below are for a typical Linux shell.
The Repos Search download contains a sample server that can be started out of the box. Instead of downloading you may check out https://labs.repos.se/data/search/trunk/.
jettysolr/run.sh.The script repos-search/svnhook.py should be called from the post-commit hook in your Subversion repository/ies. Example:
This example is for bash shell.
2>&1 is to get all output to the same log.
& is to lte post-commit exit immediately (indexing might be slow).
To rebuild the index from revision 0 to HEAD use the rebuild_index.py script,
Call the python scripts with --help to see the options.
Place the repos-search/ folder in your document root.
Then add the following to your HTML's <head>:
In Repos Style 2.3 simply uncomment the Repos Search block in repos.xsl.
Most production setups of Repos Search will be customized.
For example local rules for indexed svn properties can be set up in the Solr schema,
found in solrhome/svnhead/conf/schema.xml.
Following a Solr principle, the schema should be self-explanatory and is not documented here.
There is no access control in Repos Search, so all users that are allowed to search will get resuts from the entire repository. However Solr never returns the contents of documents, only the path.
The sample search server has no access restrictions.
It runs on a custom port (8080 by default) that is normally open for local access only,
so it is sufficient to protect the proxy in /repos-search/.
Please use the Repos Style mailing list.
Repos Search is Apache License, Version 2.0.