| 1 | | Index: setup.py |
|---|
| 2 | | =================================================================== |
|---|
| 3 | | --- setup.py (revision 1962) |
|---|
| 4 | | +++ setup.py (working copy) |
|---|
| 5 | | @@ -211,7 +211,7 @@ |
|---|
| 6 | | url=URL, |
|---|
| 7 | | packages=['trac', 'trac.mimeview', 'trac.scripts', 'trac.ticket', |
|---|
| 8 | | 'trac.upgrades', 'trac.versioncontrol', 'trac.web', |
|---|
| 9 | | - 'trac.wiki'], |
|---|
| 10 | | + 'trac.wiki', 'trac.admin'], |
|---|
| 11 | | data_files=[(_p('share/trac/templates'), glob('templates/*')), |
|---|
| 12 | | (_p('share/trac/htdocs'), glob(_p('htdocs/*.*')) + [_p('htdocs/README')]), |
|---|
| 13 | | (_p('share/trac/htdocs/css'), glob(_p('htdocs/css/*'))), |
|---|
| | 21 | +class IAdminConsoleProvider(Interface): |
|---|
| | 22 | + """ |
|---|
| | 23 | + Extension point interface for components to provide an administrative |
|---|
| | 24 | + interface from within trac-admin. |
|---|
| | 25 | + """ |
|---|
| | 26 | |
|---|
| | 27 | + def get_console_commands(tracadm): |
|---|
| | 28 | + """ |
|---|
| | 29 | + Return an iterable of (name, help, callable, completer) tuples. |
|---|
| | 30 | + |
|---|
| | 31 | + tracadm is a TracAdmin instance. |
|---|
| | 32 | + |
|---|
| | 33 | + completer can be null. help is in the same format that trac-admin |
|---|
| | 34 | + uses. |
|---|
| | 35 | + """ |
|---|
| | 36 | + |
|---|
| 131 | | Index: trac/admin/__init__.py |
|---|
| 132 | | =================================================================== |
|---|
| 133 | | --- trac/admin/__init__.py (revision 0) |
|---|
| 134 | | +++ trac/admin/__init__.py (revision 0) |
|---|
| 135 | | @@ -0,0 +1 @@ |
|---|
| 136 | | +from trac.admin.console import * |
|---|
| 137 | | Index: trac/admin/console.py |
|---|
| 138 | | =================================================================== |
|---|
| 139 | | --- trac/admin/console.py (revision 0) |
|---|
| 140 | | +++ trac/admin/console.py (revision 0) |
|---|
| 141 | | @@ -0,0 +1,41 @@ |
|---|
| 142 | | +# -*- coding: iso8859-1 -*- |
|---|
| 143 | | +# |
|---|
| 144 | | +# Copyright (C) 2003, 2004, 2005 Edgewall Software |
|---|
| 145 | | +# Copyright (C) 2003, 2004, 2005 Alec Thomas <alec@swapoff.org> |
|---|
| 146 | | +# |
|---|
| 147 | | +# Trac is free software; you can redistribute it and/or |
|---|
| 148 | | +# modify it under the terms of the GNU General Public License as |
|---|
| 149 | | +# published by the Free Software Foundation; either version 2 of the |
|---|
| 150 | | +# License, or (at your option) any later version. |
|---|
| 151 | | +# |
|---|
| 152 | | +# Trac is distributed in the hope that it will be useful, |
|---|
| 153 | | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 154 | | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|---|
| 155 | | +# General Public License for more details. |
|---|
| 156 | | +# |
|---|
| 157 | | +# You should have received a copy of the GNU General Public License |
|---|
| 158 | | +# along with this program; if not, write to the Free Software |
|---|
| 159 | | +# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
|---|
| 160 | | +# |
|---|
| 161 | | +# Author: Alec Thomas <alec@swapoff.org> |
|---|
| 162 | | + |
|---|
| 163 | | +from trac.core import Interface |
|---|
| 164 | | +import sys |
|---|
| 165 | | + |
|---|
| 166 | | +__all__ = [ 'IAdminConsoleProvider' ] |
|---|
| 167 | | + |
|---|
| 168 | | +class IAdminConsoleProvider(Interface): |
|---|
| 169 | | + """ |
|---|
| 170 | | + Extension point interface for components to provide an administrative |
|---|
| 171 | | + interface from within trac-admin. |
|---|
| 172 | | + """ |
|---|
| 173 | | + |
|---|
| 174 | | + def get_console_commands(tracadm): |
|---|
| 175 | | + """ |
|---|
| 176 | | + Return an iterable of (name, help, callable, completer) tuples. |
|---|
| 177 | | + |
|---|
| 178 | | + tracadm is a TracAdmin instance. |
|---|
| 179 | | + |
|---|
| 180 | | + completer can be null. help is in the same format that trac-admin |
|---|
| 181 | | + uses. |
|---|
| 182 | | + """ |
|---|