Changes between Version 3 and Version 4 of TracRepositoryAdmin
- Timestamp:
- 2016-01-09T17:05:34+01:00 (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
TracRepositoryAdmin
v3 v4 79 79 Note that the default repository has an empty name, so it will likely need to be quoted when running `trac-admin` from a shell. Alternatively, the name "`(default)`" can be used instead, for example when running `trac-admin` in interactive mode. 80 80 81 == Repository caching 82 83 The Subversion and Git repository connectors support caching, which improves the performance browsing the repository, viewing logs and viewing changesets. Cached repositories must be [#Synchronization synchronized]; either explicit or implicit synchronization can be used. When searching changesets, only cached repositories are searched. 84 85 Subversion repositories are cached unless the type is `direct-svnfs`. Git repositories are cached when `[git]` [wiki:TracIni#git-section cached_repository] is `true`. 81 86 82 87 == Repository synchronization #Synchronization … … 144 149 {{{#!sh 145 150 #!/bin/sh 151 tracenv=/path/to/env # change with your Trac environment's path 152 repos= # change with your repository's name 146 153 while read oldrev newrev refname; do 147 git rev-list --reverse $newrev ^$oldrev | \ 148 while read rev; do 149 trac-admin /path/to/env changeset added <repos> $rev 150 done 154 if [ "$oldrev" = 0000000000000000000000000000000000000000 ]; then 155 git rev-list --reverse "$newrev" -- 156 else 157 git rev-list --reverse "$newrev" "^$oldrev" -- 158 fi | xargs trac-admin "$tracenv" changeset added "$repos" 151 159 done 152 160 }}}