[PATCH 2/2] added small HACKING file
Christoph Höger <choeger <at> cs.tu-berlin.de>
2009-09-04 09:13:47 GMT
Signed-off-by: Christoph H=F6ger <choeger <at> cs.tu-berlin.de>
---
HACKING | 11 +++++++++++
1 files changed, 11 insertions(+), 0 deletions(-)
create mode 100644 HACKING
diff --git a/HACKING b/HACKING
new file mode 100644
index 0000000..8c6fb19
--- /dev/null
+++ b/HACKING
<at> <at> -0,0 +1,11 <at> <at>
+Developing your own UI
+=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
+
+You can develop your own plugin by simply subclassing the UIBase class f=
rom offlineimap.ui.UIBase (have a look at TTYUI for a basic understanding=
of that).
+In difference to versions <=3D 6.2.0 you can now easily activate your pl=
ugin by putting it into the offlineimap/ui/plugins folder. This works wit=
hout any other preparation. So if your module is named foo.py and your UI=
class is Bar the user can now use it with offlineimap -u foo.Bar
+If you want to make the life of the user even easier, just add a getUICl=
ass() method in your module, let's say:
+
+ # note: you return a class, not the instance!
+ def getUIClass(): return Bar
+
+Then the user can run offlineimap -u foo even without knowing about Bar =
(allowing for multiple UI Classes in one module).
(Continue reading)