[[PageOutline(2-5,Contents,pullout)]] = Search the source code repository == Description This plugin allows users to search the source code repository (TracBrowser). See also TracSuposePlugin and MultiRepoSearchPlugin. If you are using Trac 0.12+ with non-SVN repositories and/or multiple repositories, try using MultiRepoSearchPlugin. == Bugs/Feature Requests Existing bugs and feature requests for RepoSearchPlugin are [report:9?COMPONENT=RepoSearchPlugin here]. If you have any issues, create a [/newticket?component=RepoSearchPlugin new ticket]. [[TicketQuery(component=RepoSearchPlugin&group=type,format=progress)]] == Download Download the zipped source from [export:reposearchplugin here]. == Source You can check out RepoSearchPlugin from [/svn/reposearchplugin here] using Subversion, or [source:reposearchplugin browse the source] with Trac. == Installation General instructions on installing Trac plugins can be found on the [TracPlugins#InstallingaTracplugin TracPlugins] page. Depending on how you do the install, you may need to add a line to your `trac.ini` file: {{{#!ini [components] tracreposearch.* = enabled }}} and then reload your web server's configuration. == Configuration To use the repository search, users must have the `REPO_SEARCH` permission. You can include and exclude parts of the repository by adding the following options to your `trac.ini` file: {{{#!ini [repo-search] include = *.py:*.txt exclude = *.pyc:*.png:*.jpg:*.gif:*/README }}} The globs are separated by your operating systems path separator, ie `:` under UNIX, `;` under Windows, and each glob is matched against the ''full'' path. Hence `*/README` instead of just `README`. '''Note''': * If you specify an absolute path glob in an `include` or `exclude` clause for a Subversion repository, then the leading slash has to be omitted, eg `exclude = trunk/old/*`. If you are using Perforce, the absolute paths need to start with two leading slashes, eg `exclude=//depot/jobs/*`. * If only `include` is specified, then the default is to exclude all other files. To speed up searches, an indexer is included. A full index will occur the first time you search the repository, which can take quite some time. Subsequent changesets will be incrementally indexed and should be pretty snappy. The indexer is enabled by default and will use the `PYTHON_EGG_CACHE` directory to store its data. You can override this location by adding the following entry to your `trac.ini` file: {{{#!ini [repo-search] index = /my/trac/env/idx }}} The `index` option is a a directory that must be writable by the web server user. The indexer should cope well with changes to the include/exclude lists. Newly included files will be indexed, and newly excluded files will be removed from the `word:file` mapping table. '''Note:''' Under Win32 you will need the [https://sourceforge.net/projects/pywin32/ pywin32 module] for the indexer to work. == Recent Changes [[ChangeLog(reposearchplugin, 3)]] == Author/Contributors '''Author:''' [wiki:athomas] [[BR]] '''Maintainer:''' [[Maintainer]] [[BR]] '''Contributors:'''