Verifying SVN symbolic rules
This page describes a simple command-line tool ('svnrules') that you can use to find branch and tag creation changes for which there may not be SVN symbolic rules defined. The tool is available on all supported platforms but the examples below feature a Linux installation.
You may have configured SVN symbolic rules in FishEye if your SVN repository structure doesn't strictly follow the Subversion Repository Layout conventions; these rules allow FishEye to understand your custom layout.
A possible consequence of not using symbolic rules for custom repository layouts, or of configuring these incorrectly, is that FishEye may not recognize separate trunk, branch and tag creation changes, and spend excessive time indexing those as genuine changes.
The svnrules tool ships with FishEye 3.0, and later versions. It parses the SVN log and compares that against the SVN symbolic rules configured in FishEye to find commits that are likely to be branch or tag creation changes for which there are no SVN symbolic rule defined.
You may find the svnrules tool helpful if you use a custom SVN repository structure, and
- you want to analyze your repositories before indexing them, to avoid excessive time spent indexing
- you wish to analyze your repository structure yourself that must remain confidential.
Disclaimer: Please note that svnrules is very simple and doesn't attempt to perform a thorough inspection of the repository. It simply scans the repository history for copy/move operations, which in most cases indicate branch or tag creation changes. Those may be genuine copy operations within a repository, so false positives may be reported.
On this page:
Running the svnrules tool
The svnrules tool ships with FishEye and can be run from the command line as follows:
You can point it to your existing FishEye instance folder with:
The tool can be safely run when FishEye is already running, because it never attempts to modify any FishEye data or configuration files. It only analyzes the given repository structure and reports copy operations that may be unrecognized tag/branch creation changes because of missing symbolic rules.
If you run the tool on a properly configured repository that has no copy operations in its history, it would generate output similar to:
Any suspected copy operations are reported similarly to this:
As you can see, there are number of warnings reported, followed by a summary of the most common issues.
Interpreting the svnrules report
|Symbolic rule evaluation outcome||Issue reported|
|path recognized to be branch or tag||No issue reported – seems we have the correct SVN symbolic rule in place|
|path recognized as a trunk||Copy operation recognized as commit to trunk, if this is branch or tag creation change consider adding symbolic rule.
False positives would be reported here where file(s) or folder(s) were genuinely copied within a trunk.
|path not recognized as trunk, branch or tag||Copy operation recognized as unknown commit, if this is branch or tag creation change consider adding symbolic rule.
You may want to advise the user to consider excluding this folder from indexing.
Internally, the tool runs the following command on the selected repository:
For large repositories this may take a significant amount of time. You may want to analyze parts of the history, using the -s and -e options:
Was this helpful?
Thanks for your feedback!