diff --git a/src/core/constants.py b/src/core/constants.py
index 97cc77f8..57cf14f9 100644
--- a/src/core/constants.py
+++ b/src/core/constants.py
@@ -176,9 +176,17 @@ class Const(object):
# PLUGIN_INFO keys
# XXX: we use PI instead of PLUG_INFO which would normally be used
# to make the header more readable
+ PI_NAME = u'name'
PI_IMPORT_NAME = u'import_name'
+ PI_MAIN = u'main'
+ PI_HANDLER = u'handler'
+ PI_TYPE = u'type'
+ PI_MODES = u'modes'
+ PI_PROTOCOLS = u'protocols'
PI_DEPENDENCIES = u'dependencies'
PI_RECOMMENDATIONS = u'recommendations'
+ PI_DESCRIPTION = u'description'
+ PI_USAGE = u'usage'
# Types
PLUG_TYPE_XEP = "XEP"
diff --git a/src/plugins/plugin_adhoc_dbus.py b/src/plugins/plugin_adhoc_dbus.py
index f150e979..35af8bc7 100644
--- a/src/plugins/plugin_adhoc_dbus.py
+++ b/src/plugins/plugin_adhoc_dbus.py
@@ -43,14 +43,14 @@ IGNORED_IFACES_START = ('org.freedesktop', 'org.qtproject', 'org.kde.KMainWindow
FLAG_LOOP = 'LOOP'
PLUGIN_INFO = {
- "name": "Ad-Hoc Commands - D-Bus",
- "import_name": "AD_HOC_DBUS",
- "type": "Misc",
- "protocols": [],
- "dependencies": ["XEP-0050"],
- "main": "AdHocDBus",
- "handler": "no",
- "description": _("""Add D-Bus management to Ad-Hoc commands""")
+ C.PI_NAME: "Ad-Hoc Commands - D-Bus",
+ C.PI_IMPORT_NAME: "AD_HOC_DBUS",
+ C.PI_TYPE: "Misc",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["XEP-0050"],
+ C.PI_MAIN: "AdHocDBus",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Add D-Bus management to Ad-Hoc commands""")
}
diff --git a/src/plugins/plugin_blog_import.py b/src/plugins/plugin_blog_import.py
index 6b136e5f..e0f7b6a4 100755
--- a/src/plugins/plugin_blog_import.py
+++ b/src/plugins/plugin_blog_import.py
@@ -35,13 +35,13 @@ import uuid
PLUGIN_INFO = {
- "name": "blog import",
- "import_name": "BLOG_IMPORT",
- "type": C.PLUG_TYPE_BLOG,
- "dependencies": ["XEP-0060", "XEP-0277", "TEXT-SYNTAXES", "UPLOAD"],
- "main": "BlogImportPlugin",
- "handler": "no",
- "description": _(u"""Blog import management:
+ C.PI_NAME: "blog import",
+ C.PI_IMPORT_NAME: "BLOG_IMPORT",
+ C.PI_TYPE: C.PLUG_TYPE_BLOG,
+ C.PI_DEPENDENCIES: ["XEP-0060", "XEP-0277", "TEXT-SYNTAXES", "UPLOAD"],
+ C.PI_MAIN: "BlogImportPlugin",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _(u"""Blog import management:
This plugin manage the different blog importers which can register to it, and handler generic importing tasks.""")
}
diff --git a/src/plugins/plugin_blog_import_dokuwiki.py b/src/plugins/plugin_blog_import_dokuwiki.py
index 18e311f5..68ce67bd 100755
--- a/src/plugins/plugin_blog_import_dokuwiki.py
+++ b/src/plugins/plugin_blog_import_dokuwiki.py
@@ -43,13 +43,13 @@ except:
raise exceptions.MissingModule(u"Missing module pillow, please download/install it from https://python-pillow.github.io")
PLUGIN_INFO = {
- "name": "Dokuwiki import",
- "import_name": "IMPORT_DOKUWIKI",
- "type": C.PLUG_TYPE_BLOG,
- "dependencies": ["BLOG_IMPORT"],
- "main": "DokuwikiImport",
- "handler": "no",
- "description": _("""Blog importer for Dokuwiki blog engine.""")
+ C.PI_NAME: "Dokuwiki import",
+ C.PI_IMPORT_NAME: "IMPORT_DOKUWIKI",
+ C.PI_TYPE: C.PLUG_TYPE_BLOG,
+ C.PI_DEPENDENCIES: ["BLOG_IMPORT"],
+ C.PI_MAIN: "DokuwikiImport",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Blog importer for Dokuwiki blog engine.""")
}
SHORT_DESC = D_(u"import posts from Dokuwiki blog engine")
diff --git a/src/plugins/plugin_blog_import_dotclear.py b/src/plugins/plugin_blog_import_dotclear.py
index 33b71a48..6f3d7884 100755
--- a/src/plugins/plugin_blog_import_dotclear.py
+++ b/src/plugins/plugin_blog_import_dotclear.py
@@ -32,13 +32,13 @@ import os.path
PLUGIN_INFO = {
- "name": "Dotclear import",
- "import_name": "IMPORT_DOTCLEAR",
- "type": C.PLUG_TYPE_BLOG,
- "dependencies": ["BLOG_IMPORT"],
- "main": "DotclearImport",
- "handler": "no",
- "description": _("""Blog importer for Dotclear blog engine.""")
+ C.PI_NAME: "Dotclear import",
+ C.PI_IMPORT_NAME: "IMPORT_DOTCLEAR",
+ C.PI_TYPE: C.PLUG_TYPE_BLOG,
+ C.PI_DEPENDENCIES: ["BLOG_IMPORT"],
+ C.PI_MAIN: "DotclearImport",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Blog importer for Dotclear blog engine.""")
}
SHORT_DESC = D_(u"import posts from Dotclear blog engine")
diff --git a/src/plugins/plugin_exp_command_export.py b/src/plugins/plugin_exp_command_export.py
index b098ae39..cd542add 100755
--- a/src/plugins/plugin_exp_command_export.py
+++ b/src/plugins/plugin_exp_command_export.py
@@ -28,14 +28,14 @@ from sat.tools import trigger
from sat.tools.utils import clean_ustr
PLUGIN_INFO = {
- "name": "Command export plugin",
- "import_name": "EXP-COMMANS-EXPORT",
- "type": "EXP",
- "protocols": [],
- "dependencies": [],
- "main": "CommandExport",
- "handler": "no",
- "description": _("""Implementation of command export""")
+ C.PI_NAME: "Command export plugin",
+ C.PI_IMPORT_NAME: "EXP-COMMANS-EXPORT",
+ C.PI_TYPE: "EXP",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "CommandExport",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Implementation of command export""")
}
class ExportCommandProtocol(protocol.ProcessProtocol):
diff --git a/src/plugins/plugin_exp_lang_detect.py b/src/plugins/plugin_exp_lang_detect.py
index 5135b1d5..853a58ab 100755
--- a/src/plugins/plugin_exp_lang_detect.py
+++ b/src/plugins/plugin_exp_lang_detect.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _, D_
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from sat.core import exceptions
@@ -31,14 +32,14 @@ identifier = LanguageIdentifier.from_modelstring(model, norm_probs=False)
PLUGIN_INFO = {
- "name": "Language detection plugin",
- "import_name": "EXP-LANG-DETECT",
- "type": "EXP",
- "protocols": [],
- "dependencies": [],
- "main": "LangDetect",
- "handler": "no",
- "description": _("""Detect and set message language when unknown""")
+ C.PI_NAME: "Language detection plugin",
+ C.PI_IMPORT_NAME: "EXP-LANG-DETECT",
+ C.PI_TYPE: "EXP",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "LangDetect",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Detect and set message language when unknown""")
}
CATEGORY = D_(u"Misc")
diff --git a/src/plugins/plugin_exp_parrot.py b/src/plugins/plugin_exp_parrot.py
index 64e35773..f3be75ab 100755
--- a/src/plugins/plugin_exp_parrot.py
+++ b/src/plugins/plugin_exp_parrot.py
@@ -27,15 +27,15 @@ from sat.core.exceptions import UnknownEntityError
#from sat.tools import trigger
PLUGIN_INFO = {
- "name": "Parrot Plugin",
- "import_name": "EXP-PARROT",
- "type": "EXP",
- "protocols": [],
- "dependencies": ["XEP-0045"],
- "recommendations": [C.TEXT_CMDS],
- "main": "Exp_Parrot",
- "handler": "no",
- "description": _(u"""Implementation of parrot mode (repeat messages between 2 entities)""")
+ C.PI_NAME: "Parrot Plugin",
+ C.PI_IMPORT_NAME: "EXP-PARROT",
+ C.PI_TYPE: "EXP",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["XEP-0045"],
+ C.PI_RECOMMENDATIONS: [C.TEXT_CMDS],
+ C.PI_MAIN: "Exp_Parrot",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _(u"""Implementation of parrot mode (repeat messages between 2 entities)""")
}
diff --git a/src/plugins/plugin_exp_pipe.py b/src/plugins/plugin_exp_pipe.py
index b81b06ac..c2e8d72b 100755
--- a/src/plugins/plugin_exp_pipe.py
+++ b/src/plugins/plugin_exp_pipe.py
@@ -30,14 +30,14 @@ NS_PIPE = 'http://salut-a-toi.org/protocol/pipe'
SECURITY_LIMIT=30
PLUGIN_INFO = {
- "name": "Pipe Plugin",
- "import_name": "EXP-PIPE",
- "type": "EXP",
- "protocols": ["EXP-PIPE"],
- "dependencies": ["XEP-0166"],
- "main": "Exp_Pipe",
- "handler": "no",
- "description": _("""Jingle Pipe Transfer experimental plugin""")
+ C.PI_NAME: "Pipe Plugin",
+ C.PI_IMPORT_NAME: "EXP-PIPE",
+ C.PI_TYPE: "EXP",
+ C.PI_PROTOCOLS: ["EXP-PIPE"],
+ C.PI_DEPENDENCIES: ["XEP-0166"],
+ C.PI_MAIN: "Exp_Pipe",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Jingle Pipe Transfer experimental plugin""")
}
CONFIRM = D_(u"{peer} wants to send you a pipe stream, do you accept ?")
diff --git a/src/plugins/plugin_misc_account.py b/src/plugins/plugin_misc_account.py
index 49f31e68..2786ec5e 100755
--- a/src/plugins/plugin_misc_account.py
+++ b/src/plugins/plugin_misc_account.py
@@ -37,15 +37,15 @@ import random
PLUGIN_INFO = {
- "name": "Account Plugin",
- "import_name": "MISC-ACCOUNT",
- "type": "MISC",
- "protocols": [],
- "dependencies": [],
- "recommendations": ['GROUPBLOG'],
- "main": "MiscAccount",
- "handler": "no",
- "description": _(u"""SàT account creation""")
+ C.PI_NAME: "Account Plugin",
+ C.PI_IMPORT_NAME: "MISC-ACCOUNT",
+ C.PI_TYPE: "MISC",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_RECOMMENDATIONS: ['GROUPBLOG'],
+ C.PI_MAIN: "MiscAccount",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _(u"""SàT account creation""")
}
CONFIG_SECTION = "plugin account"
diff --git a/src/plugins/plugin_misc_android.py b/src/plugins/plugin_misc_android.py
index d3797d11..46b3b4a0 100644
--- a/src/plugins/plugin_misc_android.py
+++ b/src/plugins/plugin_misc_android.py
@@ -27,12 +27,12 @@ import mmap
PLUGIN_INFO = {
- "name": "Android ",
- "import_name": "android",
- "type": C.PLUG_TYPE_MISC,
- "main": "AndroidPlugin",
- "handler": "no",
- "description": D_("""Manage Android platform specificities, like pause or notifications""")
+ C.PI_NAME: "Android ",
+ C.PI_IMPORT_NAME: "android",
+ C.PI_TYPE: C.PLUG_TYPE_MISC,
+ C.PI_MAIN: "AndroidPlugin",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: D_("""Manage Android platform specificities, like pause or notifications""")
}
if sys.platform != "android":
diff --git a/src/plugins/plugin_misc_debug.py b/src/plugins/plugin_misc_debug.py
index b0b1a264..b05f67e1 100755
--- a/src/plugins/plugin_misc_debug.py
+++ b/src/plugins/plugin_misc_debug.py
@@ -24,14 +24,14 @@ from sat.core.constants import Const as C
import json
PLUGIN_INFO = {
- "name": "Debug Plugin",
- "import_name": "DEBUG",
- "type": "Misc",
- "protocols": [],
- "dependencies": [],
- "main": "Debug",
- "handler": "no",
- "description": _("""Set of method to make development and debugging easier""")
+ C.PI_NAME: "Debug Plugin",
+ C.PI_IMPORT_NAME: "DEBUG",
+ C.PI_TYPE: "Misc",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "Debug",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Set of method to make development and debugging easier""")
}
diff --git a/src/plugins/plugin_misc_extra_pep.py b/src/plugins/plugin_misc_extra_pep.py
index 9545d7b9..2ef46a6a 100644
--- a/src/plugins/plugin_misc_extra_pep.py
+++ b/src/plugins/plugin_misc_extra_pep.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _, D_
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from sat.memory import params
@@ -25,15 +26,15 @@ from twisted.words.protocols.jabber import jid
PLUGIN_INFO = {
- "name": "Extra PEP",
- "import_name": "EXTRA-PEP",
- "type": "MISC",
- "protocols": [],
- "dependencies": [],
- "recommendations": [],
- "main": "ExtraPEP",
- "handler": "no",
- "description": _(u"""Display messages from extra PEP services""")
+ C.PI_NAME: "Extra PEP",
+ C.PI_IMPORT_NAME: "EXTRA-PEP",
+ C.PI_TYPE: "MISC",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_RECOMMENDATIONS: [],
+ C.PI_MAIN: "ExtraPEP",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _(u"""Display messages from extra PEP services""")
}
diff --git a/src/plugins/plugin_misc_file.py b/src/plugins/plugin_misc_file.py
index 189bab48..f5b2e15c 100644
--- a/src/plugins/plugin_misc_file.py
+++ b/src/plugins/plugin_misc_file.py
@@ -31,12 +31,12 @@ import uuid
PLUGIN_INFO = {
- "name": "File Tansfer",
- "import_name": "FILE",
- "type": C.PLUG_TYPE_MISC,
- "main": "FilePlugin",
- "handler": "no",
- "description": _("""File Tansfer Management:
+ C.PI_NAME: "File Tansfer",
+ C.PI_IMPORT_NAME: "FILE",
+ C.PI_TYPE: C.PLUG_TYPE_MISC,
+ C.PI_MAIN: "FilePlugin",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""File Tansfer Management:
This plugin manage the various ways of sending a file, and choose the best one.""")
}
diff --git a/src/plugins/plugin_misc_groupblog.py b/src/plugins/plugin_misc_groupblog.py
index 4bc034b8..1314c7b1 100755
--- a/src/plugins/plugin_misc_groupblog.py
+++ b/src/plugins/plugin_misc_groupblog.py
@@ -41,14 +41,14 @@ NS_PUBSUB_ITEM_CONFIG = NS_PUBSUB_EXP + "#item-config"
PLUGIN_INFO = {
- "name": "Group blogging through collections",
- "import_name": "GROUPBLOG",
- "type": "MISC",
- "protocols": [],
- "dependencies": ["XEP-0277"],
- "main": "GroupBlog",
- "handler": "yes",
- "description": _("""Implementation of microblogging fine permissions""")
+ C.PI_NAME: "Group blogging through collections",
+ C.PI_IMPORT_NAME: "GROUPBLOG",
+ C.PI_TYPE: "MISC",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["XEP-0277"],
+ C.PI_MAIN: "GroupBlog",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of microblogging fine permissions""")
}
diff --git a/src/plugins/plugin_misc_imap.py b/src/plugins/plugin_misc_imap.py
index ece08d60..df595847 100755
--- a/src/plugins/plugin_misc_imap.py
+++ b/src/plugins/plugin_misc_imap.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from twisted.internet import protocol, defer
@@ -33,14 +34,14 @@ from twisted.internet import reactor
from zope.interface import implements
PLUGIN_INFO = {
- "name": "IMAP server Plugin",
- "import_name": "IMAP",
- "type": "Misc",
- "protocols": [],
- "dependencies": ["Maildir"],
- "main": "IMAP_server",
- "handler": "no",
- "description": _("""Create an Imap server that you can use to read your "normal" type messages""")
+ C.PI_NAME: "IMAP server Plugin",
+ C.PI_IMPORT_NAME: "IMAP",
+ C.PI_TYPE: "Misc",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["Maildir"],
+ C.PI_MAIN: "IMAP_server",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Create an Imap server that you can use to read your "normal" type messages""")
}
diff --git a/src/plugins/plugin_misc_ip.py b/src/plugins/plugin_misc_ip.py
index fc0ef86b..014edbc4 100644
--- a/src/plugins/plugin_misc_ip.py
+++ b/src/plugins/plugin_misc_ip.py
@@ -42,14 +42,14 @@ except ImportError:
PLUGIN_INFO = {
- "name": "IP discovery",
- "import_name": "IP",
- "type": C.PLUG_TYPE_MISC,
- "protocols": ["XEP-0279"],
- "recommendations": ["NAT-PORT"],
- "main": "IPPlugin",
- "handler": "yes",
- "description": _("""This plugin help to discover our external IP address.""")
+ C.PI_NAME: "IP discovery",
+ C.PI_IMPORT_NAME: "IP",
+ C.PI_TYPE: C.PLUG_TYPE_MISC,
+ C.PI_PROTOCOLS: ["XEP-0279"],
+ C.PI_RECOMMENDATIONS: ["NAT-PORT"],
+ C.PI_MAIN: "IPPlugin",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""This plugin help to discover our external IP address.""")
}
# TODO: GET_IP_PAGE should be configurable in sat.conf
diff --git a/src/plugins/plugin_misc_maildir.py b/src/plugins/plugin_misc_maildir.py
index e973c15a..0e551c42 100755
--- a/src/plugins/plugin_misc_maildir.py
+++ b/src/plugins/plugin_misc_maildir.py
@@ -32,14 +32,14 @@ from sat.memory.persistent import PersistentBinaryDict
PLUGIN_INFO = {
- "name": "Maildir Plugin",
- "import_name": "Maildir",
- "type": "Misc",
- "protocols": [],
- "dependencies": [],
- "main": "MaildirBox",
- "handler": "no",
- "description": _("""Intercept "normal" type messages, and put them in a Maildir type box""")
+ C.PI_NAME: "Maildir Plugin",
+ C.PI_IMPORT_NAME: "Maildir",
+ C.PI_TYPE: "Misc",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "MaildirBox",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Intercept "normal" type messages, and put them in a Maildir type box""")
}
MAILDIR_PATH = "Maildir"
diff --git a/src/plugins/plugin_misc_nat-port.py b/src/plugins/plugin_misc_nat-port.py
index 189acc73..2b904b50 100644
--- a/src/plugins/plugin_misc_nat-port.py
+++ b/src/plugins/plugin_misc_nat-port.py
@@ -34,12 +34,12 @@ except ImportError:
PLUGIN_INFO = {
- "name": "NAT port mapping",
- "import_name": "NAT-PORT",
- "type": C.PLUG_TYPE_MISC,
- "main": "NatPort",
- "handler": "no",
- "description": _("""Automatic NAT port mapping using UPnP"""),
+ C.PI_NAME: "NAT port mapping",
+ C.PI_IMPORT_NAME: "NAT-PORT",
+ C.PI_TYPE: C.PLUG_TYPE_MISC,
+ C.PI_MAIN: "NatPort",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Automatic NAT port mapping using UPnP"""),
}
STARTING_PORT = 6000 # starting point to automatically find a port
diff --git a/src/plugins/plugin_misc_quiz.py b/src/plugins/plugin_misc_quiz.py
index 7adf03a4..f2fbcd27 100755
--- a/src/plugins/plugin_misc_quiz.py
+++ b/src/plugins/plugin_misc_quiz.py
@@ -31,14 +31,14 @@ NS_QG = 'http://www.goffi.org/protocol/quiz'
QG_TAG = 'quiz'
PLUGIN_INFO = {
- "name": "Quiz game plugin",
- "import_name": "Quiz",
- "type": "Game",
- "protocols": [],
- "dependencies": ["XEP-0045", "XEP-0249", "ROOM-GAME"],
- "main": "Quiz",
- "handler": "yes",
- "description": _("""Implementation of Quiz game""")
+ C.PI_NAME: "Quiz game plugin",
+ C.PI_IMPORT_NAME: "Quiz",
+ C.PI_TYPE: "Game",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["XEP-0045", "XEP-0249", "ROOM-GAME"],
+ C.PI_MAIN: "Quiz",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Quiz game""")
}
diff --git a/src/plugins/plugin_misc_radiocol.py b/src/plugins/plugin_misc_radiocol.py
index fa1e9dff..06a62465 100755
--- a/src/plugins/plugin_misc_radiocol.py
+++ b/src/plugins/plugin_misc_radiocol.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _, D_
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from twisted.words.xish import domish
@@ -42,14 +43,14 @@ NC_RADIOCOL = 'http://www.goffi.org/protocol/radiocol'
RADIOC_TAG = 'radiocol'
PLUGIN_INFO = {
- "name": "Radio collective plugin",
- "import_name": "Radiocol",
- "type": "Exp",
- "protocols": [],
- "dependencies": ["XEP-0045", "XEP-0249", "ROOM-GAME"],
- "main": "Radiocol",
- "handler": "yes",
- "description": _("""Implementation of radio collective""")
+ C.PI_NAME: "Radio collective plugin",
+ C.PI_IMPORT_NAME: "Radiocol",
+ C.PI_TYPE: "Exp",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["XEP-0045", "XEP-0249", "ROOM-GAME"],
+ C.PI_MAIN: "Radiocol",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of radio collective""")
}
diff --git a/src/plugins/plugin_misc_register_account.py b/src/plugins/plugin_misc_register_account.py
index 39a3ebcc..6223a3b3 100644
--- a/src/plugins/plugin_misc_register_account.py
+++ b/src/plugins/plugin_misc_register_account.py
@@ -31,15 +31,15 @@ from sat.tools.xml_tools import SAT_FORM_PREFIX, SAT_PARAM_SEPARATOR
PLUGIN_INFO = {
- "name": "Register Account Plugin",
- "import_name": "REGISTER-ACCOUNT",
- "type": "MISC",
- "protocols": [],
- "dependencies": [],
- "recommendations": [],
- "main": "RegisterAccount",
- "handler": "no",
- "description": _(u"""Register XMPP account""")
+ C.PI_NAME: "Register Account Plugin",
+ C.PI_IMPORT_NAME: "REGISTER-ACCOUNT",
+ C.PI_TYPE: "MISC",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_RECOMMENDATIONS: [],
+ C.PI_MAIN: "RegisterAccount",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _(u"""Register XMPP account""")
}
diff --git a/src/plugins/plugin_misc_room_game.py b/src/plugins/plugin_misc_room_game.py
index 7db586c7..9f5d54d6 100644
--- a/src/plugins/plugin_misc_room_game.py
+++ b/src/plugins/plugin_misc_room_game.py
@@ -37,14 +37,14 @@ except ImportError:
_DEBUG = False
PLUGIN_INFO = {
- "name": "Room game",
- "import_name": "ROOM-GAME",
- "type": "MISC",
- "protocols": [],
- "dependencies": ["XEP-0045", "XEP-0249"],
- "main": "RoomGame",
- "handler": "no", # handler MUST be "no" (dynamic inheritance)
- "description": _("""Base class for MUC games""")
+ C.PI_NAME: "Room game",
+ C.PI_IMPORT_NAME: "ROOM-GAME",
+ C.PI_TYPE: "MISC",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["XEP-0045", "XEP-0249"],
+ C.PI_MAIN: "RoomGame",
+ C.PI_HANDLER: "no", # handler MUST be "no" (dynamic inheritance)
+ C.PI_DESCRIPTION: _("""Base class for MUC games""")
}
diff --git a/src/plugins/plugin_misc_smtp.py b/src/plugins/plugin_misc_smtp.py
index 7bba0d4e..0301a6b5 100755
--- a/src/plugins/plugin_misc_smtp.py
+++ b/src/plugins/plugin_misc_smtp.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from twisted.internet import defer
@@ -34,14 +35,14 @@ import sys
from zope.interface import implements
PLUGIN_INFO = {
- "name": "SMTP server Plugin",
- "import_name": "SMTP",
- "type": "Misc",
- "protocols": [],
- "dependencies": ["Maildir"],
- "main": "SMTP_server",
- "handler": "no",
- "description": _("""Create a SMTP server that you can use to send your "normal" type messages""")
+ C.PI_NAME: "SMTP server Plugin",
+ C.PI_IMPORT_NAME: "SMTP",
+ C.PI_TYPE: "Misc",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["Maildir"],
+ C.PI_MAIN: "SMTP_server",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Create a SMTP server that you can use to send your "normal" type messages""")
}
diff --git a/src/plugins/plugin_misc_static_blog.py b/src/plugins/plugin_misc_static_blog.py
index 850f41a3..944389ed 100644
--- a/src/plugins/plugin_misc_static_blog.py
+++ b/src/plugins/plugin_misc_static_blog.py
@@ -30,15 +30,15 @@ from twisted.words.protocols.jabber import jid
PLUGIN_INFO = {
- "name": "Static Blog Plugin",
- "import_name": "STATIC-BLOG",
- "type": "MISC",
- "protocols": [],
- "dependencies": [],
- "recommendations": ['MISC-ACCOUNT'], # TODO: remove when all blogs can be retrieved
- "main": "StaticBlog",
- "handler": "no",
- "description": _("""Plugin for static blogs""")
+ C.PI_NAME: "Static Blog Plugin",
+ C.PI_IMPORT_NAME: "STATIC-BLOG",
+ C.PI_TYPE: "MISC",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_RECOMMENDATIONS: ['MISC-ACCOUNT'], # TODO: remove when all blogs can be retrieved
+ C.PI_MAIN: "StaticBlog",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Plugin for static blogs""")
}
diff --git a/src/plugins/plugin_misc_tarot.py b/src/plugins/plugin_misc_tarot.py
index 6ad354b2..459c222d 100755
--- a/src/plugins/plugin_misc_tarot.py
+++ b/src/plugins/plugin_misc_tarot.py
@@ -36,14 +36,14 @@ NS_CG = 'http://www.goffi.org/protocol/card_game'
CG_TAG = 'card_game'
PLUGIN_INFO = {
- "name": "Tarot cards plugin",
- "import_name": "Tarot",
- "type": "Misc",
- "protocols": [],
- "dependencies": ["XEP-0045", "XEP-0249", "ROOM-GAME"],
- "main": "Tarot",
- "handler": "yes",
- "description": _("""Implementation of Tarot card game""")
+ C.PI_NAME: "Tarot cards plugin",
+ C.PI_IMPORT_NAME: "Tarot",
+ C.PI_TYPE: "Misc",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["XEP-0045", "XEP-0249", "ROOM-GAME"],
+ C.PI_MAIN: "Tarot",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Tarot card game""")
}
diff --git a/src/plugins/plugin_misc_text_commands.py b/src/plugins/plugin_misc_text_commands.py
index 399d4891..c16f70eb 100755
--- a/src/plugins/plugin_misc_text_commands.py
+++ b/src/plugins/plugin_misc_text_commands.py
@@ -28,14 +28,14 @@ from twisted.python import failure
from collections import OrderedDict
PLUGIN_INFO = {
- "name": "Text commands",
- "import_name": C.TEXT_CMDS,
- "type": "Misc",
- "protocols": ["XEP-0245"],
- "dependencies": [],
- "main": "TextCommands",
- "handler": "no",
- "description": _("""IRC like text commands""")
+ C.PI_NAME: "Text commands",
+ C.PI_IMPORT_NAME: C.TEXT_CMDS,
+ C.PI_TYPE: "Misc",
+ C.PI_PROTOCOLS: ["XEP-0245"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "TextCommands",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""IRC like text commands""")
}
diff --git a/src/plugins/plugin_misc_text_syntaxes.py b/src/plugins/plugin_misc_text_syntaxes.py
index 1fa34fd6..7aac8cfe 100755
--- a/src/plugins/plugin_misc_text_syntaxes.py
+++ b/src/plugins/plugin_misc_text_syntaxes.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _, D_
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
@@ -52,14 +53,14 @@ STYLES_VALUES_REGEX = r'^(' + '|'.join(['([a-z-]+)', # alphabetical names
STYLES_ACCEPTED_VALUE = re.compile(STYLES_VALUES_REGEX)
PLUGIN_INFO = {
- "name": "Text syntaxes",
- "import_name": "TEXT-SYNTAXES",
- "type": "MISC",
- "protocols": [],
- "dependencies": [],
- "main": "TextSyntaxes",
- "handler": "no",
- "description": _("""Management of various text syntaxes (XHTML-IM, Markdown, etc)""")
+ C.PI_NAME: "Text syntaxes",
+ C.PI_IMPORT_NAME: "TEXT-SYNTAXES",
+ C.PI_TYPE: "MISC",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "TextSyntaxes",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Management of various text syntaxes (XHTML-IM, Markdown, etc)""")
}
class UnknownSyntax(Exception):
diff --git a/src/plugins/plugin_misc_upload.py b/src/plugins/plugin_misc_upload.py
index 8af7bd23..6db5122a 100644
--- a/src/plugins/plugin_misc_upload.py
+++ b/src/plugins/plugin_misc_upload.py
@@ -30,12 +30,12 @@ import os.path
PLUGIN_INFO = {
- "name": "File Upload",
- "import_name": "UPLOAD",
- "type": C.PLUG_TYPE_MISC,
- "main": "UploadPlugin",
- "handler": "no",
- "description": _("""File upload management""")
+ C.PI_NAME: "File Upload",
+ C.PI_IMPORT_NAME: "UPLOAD",
+ C.PI_TYPE: C.PLUG_TYPE_MISC,
+ C.PI_MAIN: "UploadPlugin",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""File upload management""")
}
diff --git a/src/plugins/plugin_misc_watched.py b/src/plugins/plugin_misc_watched.py
index 57d880cc..1c0b2b7e 100755
--- a/src/plugins/plugin_misc_watched.py
+++ b/src/plugins/plugin_misc_watched.py
@@ -26,14 +26,14 @@ from sat.tools import xml_tools
PLUGIN_INFO = {
- "name": "Watched",
- "import_name": "WATCHED",
- "type": "Misc",
- "protocols": [],
- "dependencies": [],
- "main": "Watched",
- "handler": "no",
- "description": _("""Watch for entities presence, and send notification accordingly""")
+ C.PI_NAME: "Watched",
+ C.PI_IMPORT_NAME: "WATCHED",
+ C.PI_TYPE: "Misc",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "Watched",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Watch for entities presence, and send notification accordingly""")
}
diff --git a/src/plugins/plugin_misc_welcome.py b/src/plugins/plugin_misc_welcome.py
index 54d68d28..5f44177b 100644
--- a/src/plugins/plugin_misc_welcome.py
+++ b/src/plugins/plugin_misc_welcome.py
@@ -25,12 +25,12 @@ from sat.tools import xml_tools
PLUGIN_INFO = {
- "name": "Welcome",
- "import_name": "WELCOME",
- "type": C.PLUG_TYPE_MISC,
- "main": "Welcome",
- "handler": "no",
- "description": _("""Plugin which manage welcome message and things to to on first connection.""")
+ C.PI_NAME: "Welcome",
+ C.PI_IMPORT_NAME: "WELCOME",
+ C.PI_TYPE: C.PLUG_TYPE_MISC,
+ C.PI_MAIN: "Welcome",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Plugin which manage welcome message and things to to on first connection.""")
}
diff --git a/src/plugins/plugin_misc_xmllog.py b/src/plugins/plugin_misc_xmllog.py
index 0177728e..704af3ce 100755
--- a/src/plugins/plugin_misc_xmllog.py
+++ b/src/plugins/plugin_misc_xmllog.py
@@ -18,20 +18,21 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from twisted.words.protocols.jabber.xmlstream import XmlStream
from twisted.words.xish import domish
PLUGIN_INFO = {
- "name": "Raw XML log Plugin",
- "import_name": "XmlLog",
- "type": "Misc",
- "protocols": [],
- "dependencies": [],
- "main": "XmlLog",
- "handler": "no",
- "description": _("""Send raw XML logs to bridge""")
+ C.PI_NAME: "Raw XML log Plugin",
+ C.PI_IMPORT_NAME: "XmlLog",
+ C.PI_TYPE: "Misc",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "XmlLog",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Send raw XML logs to bridge""")
}
diff --git a/src/plugins/plugin_sec_otr.py b/src/plugins/plugin_sec_otr.py
index a7962c3a..734eed2d 100644
--- a/src/plugins/plugin_sec_otr.py
+++ b/src/plugins/plugin_sec_otr.py
@@ -37,14 +37,14 @@ import uuid
PLUGIN_INFO = {
- "name": u"OTR",
- "import_name": u"OTR",
- "type": u"SEC",
- "protocols": [u"XEP-0364"],
- "dependencies": [u"XEP-0280", u"XEP-0334"],
- "main": u"OTR",
- "handler": u"no",
- "description": _(u"""Implementation of OTR""")
+ C.PI_NAME: u"OTR",
+ C.PI_IMPORT_NAME: u"OTR",
+ C.PI_TYPE: u"SEC",
+ C.PI_PROTOCOLS: [u"XEP-0364"],
+ C.PI_DEPENDENCIES: [u"XEP-0280", u"XEP-0334"],
+ C.PI_MAIN: u"OTR",
+ C.PI_HANDLER: u"no",
+ C.PI_DESCRIPTION: _(u"""Implementation of OTR""")
}
NS_OTR = "otr_plugin"
diff --git a/src/plugins/plugin_syntax_wiki_dotclear.py b/src/plugins/plugin_syntax_wiki_dotclear.py
index c0c49f81..3bbff4e3 100644
--- a/src/plugins/plugin_syntax_wiki_dotclear.py
+++ b/src/plugins/plugin_syntax_wiki_dotclear.py
@@ -30,13 +30,13 @@ import copy
import re
PLUGIN_INFO = {
- "name": "Dotclear Wiki Syntax Plugin",
- "import_name": "SYNT_DC_WIKI",
- "type": C.PLUG_TYPE_SYNTAXE,
- "dependencies": ["TEXT-SYNTAXES"],
- "main": "DCWikiSyntax",
- "handler": "",
- "description": _("""Implementation of Dotclear wiki syntax""")
+ C.PI_NAME: "Dotclear Wiki Syntax Plugin",
+ C.PI_IMPORT_NAME: "SYNT_DC_WIKI",
+ C.PI_TYPE: C.PLUG_TYPE_SYNTAXE,
+ C.PI_DEPENDENCIES: ["TEXT-SYNTAXES"],
+ C.PI_MAIN: "DCWikiSyntax",
+ C.PI_HANDLER: "",
+ C.PI_DESCRIPTION: _("""Implementation of Dotclear wiki syntax""")
}
NOTE_TPL = u'[{}]' # Note template
diff --git a/src/plugins/plugin_tmp_directory_subscription.py b/src/plugins/plugin_tmp_directory_subscription.py
index 613c50c2..5cc6fae2 100644
--- a/src/plugins/plugin_tmp_directory_subscription.py
+++ b/src/plugins/plugin_tmp_directory_subscription.py
@@ -19,20 +19,21 @@
# along with this program. If not, see .
from sat.core.i18n import _, D_
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
PLUGIN_INFO = {
- "name": "Directory subscription plugin",
- "import_name": "DIRECTORY-SUBSCRIPTION",
- "type": "TMP",
- "protocols": [],
- "dependencies": ["XEP-0050", "XEP-0055"],
- "recommendations": [],
- "main": "DirectorySubscription",
- "handler": "no",
- "description": _("""Implementation of directory subscription""")
+ C.PI_NAME: "Directory subscription plugin",
+ C.PI_IMPORT_NAME: "DIRECTORY-SUBSCRIPTION",
+ C.PI_TYPE: "TMP",
+ C.PI_PROTOCOLS: [],
+ C.PI_DEPENDENCIES: ["XEP-0050", "XEP-0055"],
+ C.PI_RECOMMENDATIONS: [],
+ C.PI_MAIN: "DirectorySubscription",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Implementation of directory subscription""")
}
@@ -55,7 +56,7 @@ class DirectorySubscription(object):
@return: a deferred dict{unicode: unicode}
"""
d = self.host.plugins["XEP-0055"]._getHostServices(profile)
-
+
def got_services(services):
service_jid = services[0]
session_id, session_data = self.host.plugins["XEP-0050"].requesting.newSession(profile=profile)
@@ -63,5 +64,5 @@ class DirectorySubscription(object):
session_data["node"] = CMD_UPDATE_SUBSCRIBTION
data = {"session_id": session_id}
return self.host.plugins["XEP-0050"]._requestingEntity(data, profile)
-
+
return d.addCallback(got_services)
diff --git a/src/plugins/plugin_xep_0020.py b/src/plugins/plugin_xep_0020.py
index f6e4619c..3df432e5 100755
--- a/src/plugins/plugin_xep_0020.py
+++ b/src/plugins/plugin_xep_0020.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from sat.core import exceptions
@@ -35,13 +36,13 @@ from wokkel import disco, iwokkel, data_form
NS_FEATURE_NEG = 'http://jabber.org/protocol/feature-neg'
PLUGIN_INFO = {
- "name": "XEP 0020 Plugin",
- "import_name": "XEP-0020",
- "type": "XEP",
- "protocols": ["XEP-0020"],
- "main": "XEP_0020",
- "handler": "yes",
- "description": _("""Implementation of Feature Negotiation""")
+ C.PI_NAME: "XEP 0020 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0020",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0020"],
+ C.PI_MAIN: "XEP_0020",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Feature Negotiation""")
}
diff --git a/src/plugins/plugin_xep_0033.py b/src/plugins/plugin_xep_0033.py
index d9207fdb..c6c0105f 100644
--- a/src/plugins/plugin_xep_0033.py
+++ b/src/plugins/plugin_xep_0033.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from sat.core import exceptions
@@ -53,14 +54,14 @@ ATTRIBUTES = ["jid", "uri", "node", "desc", "delivered", "type"]
ADDRESS_TYPES = ["to", "cc", "bcc", "replyto", "replyroom", "noreply"]
PLUGIN_INFO = {
- "name": "Extended Stanza Addressing Protocol Plugin",
- "import_name": "XEP-0033",
- "type": "XEP",
- "protocols": ["XEP-0033"],
- "dependencies": [],
- "main": "XEP_0033",
- "handler": "yes",
- "description": _("""Implementation of Extended Stanza Addressing""")
+ C.PI_NAME: "Extended Stanza Addressing Protocol Plugin",
+ C.PI_IMPORT_NAME: "XEP-0033",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0033"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "XEP_0033",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Extended Stanza Addressing""")
}
diff --git a/src/plugins/plugin_xep_0045.py b/src/plugins/plugin_xep_0045.py
index 32dab257..e4b11ca6 100755
--- a/src/plugins/plugin_xep_0045.py
+++ b/src/plugins/plugin_xep_0045.py
@@ -41,15 +41,15 @@ from zope.interface import implements
PLUGIN_INFO = {
- "name": "XEP-0045 Plugin",
- "import_name": "XEP-0045",
- "type": "XEP",
- "protocols": ["XEP-0045"],
- "dependencies": [],
- "recommendations": [C.TEXT_CMDS],
- "main": "XEP_0045",
- "handler": "yes",
- "description": _("""Implementation of Multi-User Chat""")
+ C.PI_NAME: "XEP-0045 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0045",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0045"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_RECOMMENDATIONS: [C.TEXT_CMDS],
+ C.PI_MAIN: "XEP_0045",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Multi-User Chat""")
}
NS_MUC = 'http://jabber.org/protocol/muc'
diff --git a/src/plugins/plugin_xep_0047.py b/src/plugins/plugin_xep_0047.py
index 423972a0..78522517 100644
--- a/src/plugins/plugin_xep_0047.py
+++ b/src/plugins/plugin_xep_0047.py
@@ -51,13 +51,13 @@ TIMEOUT = 120 # timeout for workflow
DEFER_KEY = 'finished' # key of the deferred used to track session end
PLUGIN_INFO = {
- "name": "In-Band Bytestream Plugin",
- "import_name": "XEP-0047",
- "type": "XEP",
- "protocols": ["XEP-0047"],
- "main": "XEP_0047",
- "handler": "yes",
- "description": _("""Implementation of In-Band Bytestreams""")
+ C.PI_NAME: "In-Band Bytestream Plugin",
+ C.PI_IMPORT_NAME: "XEP-0047",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0047"],
+ C.PI_MAIN: "XEP_0047",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of In-Band Bytestreams""")
}
diff --git a/src/plugins/plugin_xep_0048.py b/src/plugins/plugin_xep_0048.py
index a06d5474..ecc5c84c 100644
--- a/src/plugins/plugin_xep_0048.py
+++ b/src/plugins/plugin_xep_0048.py
@@ -33,15 +33,15 @@ from twisted.internet import defer
NS_BOOKMARKS = 'storage:bookmarks'
PLUGIN_INFO = {
- "name": "Bookmarks",
- "import_name": "XEP-0048",
- "type": "XEP",
- "protocols": ["XEP-0048"],
- "dependencies": ["XEP-0045"],
- "recommendations": ["XEP-0049"],
- "main": "XEP_0048",
- "handler": "no",
- "description": _("""Implementation of bookmarks""")
+ C.PI_NAME: "Bookmarks",
+ C.PI_IMPORT_NAME: "XEP-0048",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0048"],
+ C.PI_DEPENDENCIES: ["XEP-0045"],
+ C.PI_RECOMMENDATIONS: ["XEP-0049"],
+ C.PI_MAIN: "XEP_0048",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Implementation of bookmarks""")
}
diff --git a/src/plugins/plugin_xep_0049.py b/src/plugins/plugin_xep_0049.py
index 697f5119..7ce7f89d 100755
--- a/src/plugins/plugin_xep_0049.py
+++ b/src/plugins/plugin_xep_0049.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from wokkel import compat
@@ -26,14 +27,14 @@ from twisted.words.xish import domish
PLUGIN_INFO = {
- "name": "XEP-0049 Plugin",
- "import_name": "XEP-0049",
- "type": "XEP",
- "protocols": ["XEP-0049"],
- "dependencies": [],
- "main": "XEP_0049",
- "handler": "no",
- "description": _("""Implementation of private XML storage""")
+ C.PI_NAME: "XEP-0049 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0049",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0049"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "XEP_0049",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Implementation of private XML storage""")
}
diff --git a/src/plugins/plugin_xep_0050.py b/src/plugins/plugin_xep_0050.py
index 85dee888..d869024a 100644
--- a/src/plugins/plugin_xep_0050.py
+++ b/src/plugins/plugin_xep_0050.py
@@ -59,13 +59,13 @@ SHOWS = OrderedDict([('default', _('Online')),
('disconnect', _('Disconnect'))])
PLUGIN_INFO = {
- "name": "Ad-Hoc Commands",
- "import_name": "XEP-0050",
- "type": "XEP",
- "protocols": ["XEP-0050"],
- "main": "XEP_0050",
- "handler": "yes",
- "description": _("""Implementation of Ad-Hoc Commands""")
+ C.PI_NAME: "Ad-Hoc Commands",
+ C.PI_IMPORT_NAME: "XEP-0050",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0050"],
+ C.PI_MAIN: "XEP_0050",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Ad-Hoc Commands""")
}
diff --git a/src/plugins/plugin_xep_0054.py b/src/plugins/plugin_xep_0054.py
index d2602fa3..50654a16 100755
--- a/src/plugins/plugin_xep_0054.py
+++ b/src/plugins/plugin_xep_0054.py
@@ -62,15 +62,15 @@ CACHED_DATA = {'avatar', 'nick'}
MAX_AGE = 60 * 60 * 24 * 365
PLUGIN_INFO = {
- "name": "XEP 0054 Plugin",
- "import_name": "XEP-0054",
- "type": "XEP",
- "protocols": ["XEP-0054", "XEP-0153"],
- "dependencies": [],
- "recommendations": ["XEP-0045"],
- "main": "XEP_0054",
- "handler": "yes",
- "description": _("""Implementation of vcard-temp""")
+ C.PI_NAME: "XEP 0054 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0054",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0054", "XEP-0153"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_RECOMMENDATIONS: ["XEP-0045"],
+ C.PI_MAIN: "XEP_0054",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of vcard-temp""")
}
diff --git a/src/plugins/plugin_xep_0055.py b/src/plugins/plugin_xep_0055.py
index 2e4d0b3a..fcee095e 100644
--- a/src/plugins/plugin_xep_0055.py
+++ b/src/plugins/plugin_xep_0055.py
@@ -40,15 +40,15 @@ from zope.interface import implements
NS_SEARCH = 'jabber:iq:search'
PLUGIN_INFO = {
- "name": "Jabber Search",
- "import_name": "XEP-0055",
- "type": "XEP",
- "protocols": ["XEP-0055"],
- "dependencies": [],
- "recommendations": ["XEP-0059"],
- "main": "XEP_0055",
- "handler": "no",
- "description": _("""Implementation of Jabber Search""")
+ C.PI_NAME: "Jabber Search",
+ C.PI_IMPORT_NAME: "XEP-0055",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0055"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_RECOMMENDATIONS: ["XEP-0059"],
+ C.PI_MAIN: "XEP_0055",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Implementation of Jabber Search""")
}
# config file parameters
diff --git a/src/plugins/plugin_xep_0059.py b/src/plugins/plugin_xep_0059.py
index 15793995..d4788c26 100644
--- a/src/plugins/plugin_xep_0059.py
+++ b/src/plugins/plugin_xep_0059.py
@@ -19,6 +19,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
@@ -31,13 +32,13 @@ from zope.interface import implements
PLUGIN_INFO = {
- "name": "Result Set Management",
- "import_name": "XEP-0059",
- "type": "XEP",
- "protocols": ["XEP-0059"],
- "main": "XEP_0059",
- "handler": "yes",
- "description": _("""Implementation of Result Set Management""")
+ C.PI_NAME: "Result Set Management",
+ C.PI_IMPORT_NAME: "XEP-0059",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0059"],
+ C.PI_MAIN: "XEP_0059",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Result Set Management""")
}
diff --git a/src/plugins/plugin_xep_0060.py b/src/plugins/plugin_xep_0060.py
index 8f98344a..a63afc04 100755
--- a/src/plugins/plugin_xep_0060.py
+++ b/src/plugins/plugin_xep_0060.py
@@ -42,15 +42,15 @@ from wokkel import mam
PLUGIN_INFO = {
- "name": "Publish-Subscribe",
- "import_name": "XEP-0060",
- "type": "XEP",
- "protocols": ["XEP-0060"],
- "dependencies": [],
- "recommendations": ["XEP-0313"],
- "main": "XEP_0060",
- "handler": "yes",
- "description": _("""Implementation of PubSub Protocol""")
+ C.PI_NAME: "Publish-Subscribe",
+ C.PI_IMPORT_NAME: "XEP-0060",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0060"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_RECOMMENDATIONS: ["XEP-0313"],
+ C.PI_MAIN: "XEP_0060",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of PubSub Protocol""")
}
UNSPECIFIED = "unspecified error"
diff --git a/src/plugins/plugin_xep_0065.py b/src/plugins/plugin_xep_0065.py
index 60d9e9df..fe4a9ea9 100755
--- a/src/plugins/plugin_xep_0065.py
+++ b/src/plugins/plugin_xep_0065.py
@@ -84,15 +84,15 @@ from wokkel import disco, iwokkel
PLUGIN_INFO = {
- "name": "XEP 0065 Plugin",
- "import_name": "XEP-0065",
- "type": "XEP",
- "protocols": ["XEP-0065"],
- "dependencies": ["IP"],
- "recommendations": ["NAT-PORT"],
- "main": "XEP_0065",
- "handler": "yes",
- "description": _("""Implementation of SOCKS5 Bytestreams""")
+ C.PI_NAME: "XEP 0065 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0065",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0065"],
+ C.PI_DEPENDENCIES: ["IP"],
+ C.PI_RECOMMENDATIONS: ["NAT-PORT"],
+ C.PI_MAIN: "XEP_0065",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of SOCKS5 Bytestreams""")
}
IQ_SET = '/iq[@type="set"]'
diff --git a/src/plugins/plugin_xep_0070.py b/src/plugins/plugin_xep_0070.py
index 7cdf5fa3..1e626c81 100644
--- a/src/plugins/plugin_xep_0070.py
+++ b/src/plugins/plugin_xep_0070.py
@@ -17,6 +17,7 @@
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see .
from sat.core.i18n import _, D_
+from sat.core.constants import Const as C
from sat.core.log import getLogger
from twisted.words.protocols.jabber import xmlstream
from twisted.words.protocols import jabber
@@ -43,14 +44,14 @@ MSG_HTTP_AUTH_REQUEST = MSG_GET + '/confirm[@xmlns="' + NS_HTTP_AUTH + '"]'
PLUGIN_INFO = {
- "name": "XEP-0070 Plugin",
- "import_name": "XEP-0070",
- "type": "XEP",
- "protocols": ["XEP-0070"],
- "dependencies": [],
- "main": "XEP_0070",
- "handler": "yes",
- "description": _("""Implementation of HTTP Requests via XMPP""")
+ C.PI_NAME: "XEP-0070 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0070",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0070"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "XEP_0070",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of HTTP Requests via XMPP""")
}
diff --git a/src/plugins/plugin_xep_0071.py b/src/plugins/plugin_xep_0071.py
index 88418571..f0c9a519 100644
--- a/src/plugins/plugin_xep_0071.py
+++ b/src/plugins/plugin_xep_0071.py
@@ -41,14 +41,14 @@ NS_XHTML_IM = 'http://jabber.org/protocol/xhtml-im'
NS_XHTML = 'http://www.w3.org/1999/xhtml'
PLUGIN_INFO = {
- "name": "XHTML-IM Plugin",
- "import_name": "XEP-0071",
- "type": "XEP",
- "protocols": ["XEP-0071"],
- "dependencies": ["TEXT-SYNTAXES"],
- "main": "XEP_0071",
- "handler": "yes",
- "description": _("""Implementation of XHTML-IM""")
+ C.PI_NAME: "XHTML-IM Plugin",
+ C.PI_IMPORT_NAME: "XEP-0071",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0071"],
+ C.PI_DEPENDENCIES: ["TEXT-SYNTAXES"],
+ C.PI_MAIN: "XEP_0071",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of XHTML-IM""")
}
allowed = {
diff --git a/src/plugins/plugin_xep_0077.py b/src/plugins/plugin_xep_0077.py
index 5637027e..f06dcf49 100755
--- a/src/plugins/plugin_xep_0077.py
+++ b/src/plugins/plugin_xep_0077.py
@@ -31,13 +31,13 @@ from wokkel import data_form, compat
NS_REG = 'jabber:iq:register'
PLUGIN_INFO = {
- "name": "XEP 0077 Plugin",
- "import_name": "XEP-0077",
- "type": "XEP",
- "protocols": ["XEP-0077"],
- "dependencies": [],
- "main": "XEP_0077",
- "description": _("""Implementation of in-band registration""")
+ C.PI_NAME: "XEP 0077 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0077",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0077"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "XEP_0077",
+ C.PI_DESCRIPTION: _("""Implementation of in-band registration""")
}
diff --git a/src/plugins/plugin_xep_0085.py b/src/plugins/plugin_xep_0085.py
index 887aaeab..aa806eb9 100755
--- a/src/plugins/plugin_xep_0085.py
+++ b/src/plugins/plugin_xep_0085.py
@@ -43,14 +43,14 @@ ENTITY_KEY = PARAM_KEY + "_" + PARAM_NAME
DELETE_VALUE = "DELETE"
PLUGIN_INFO = {
- "name": "Chat State Notifications Protocol Plugin",
- "import_name": "XEP-0085",
- "type": "XEP",
- "protocols": ["XEP-0085"],
- "dependencies": [],
- "main": "XEP_0085",
- "handler": "yes",
- "description": _("""Implementation of Chat State Notifications Protocol""")
+ C.PI_NAME: "Chat State Notifications Protocol Plugin",
+ C.PI_IMPORT_NAME: "XEP-0085",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0085"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "XEP_0085",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Chat State Notifications Protocol""")
}
diff --git a/src/plugins/plugin_xep_0092.py b/src/plugins/plugin_xep_0092.py
index f274025e..9609305d 100644
--- a/src/plugins/plugin_xep_0092.py
+++ b/src/plugins/plugin_xep_0092.py
@@ -30,15 +30,15 @@ NS_VERSION = "jabber:iq:version"
TIMEOUT = 10
PLUGIN_INFO = {
- "name": "Software Version Plugin",
- "import_name": "XEP-0092",
- "type": "XEP",
- "protocols": ["XEP-0092"],
- "dependencies": [],
- "recommendations": [C.TEXT_CMDS],
- "main": "XEP_0092",
- "handler": "no", # version is already handler in core.xmpp module
- "description": _("""Implementation of Software Version""")
+ C.PI_NAME: "Software Version Plugin",
+ C.PI_IMPORT_NAME: "XEP-0092",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0092"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_RECOMMENDATIONS: [C.TEXT_CMDS],
+ C.PI_MAIN: "XEP_0092",
+ C.PI_HANDLER: "no", # version is already handler in core.xmpp module
+ C.PI_DESCRIPTION: _("""Implementation of Software Version""")
}
diff --git a/src/plugins/plugin_xep_0095.py b/src/plugins/plugin_xep_0095.py
index a90d324a..42dafdee 100644
--- a/src/plugins/plugin_xep_0095.py
+++ b/src/plugins/plugin_xep_0095.py
@@ -31,13 +31,13 @@ import uuid
PLUGIN_INFO = {
- "name": "XEP 0095 Plugin",
- "import_name": "XEP-0095",
- "type": "XEP",
- "protocols": ["XEP-0095"],
- "main": "XEP_0095",
- "handler": "yes",
- "description": _("""Implementation of Stream Initiation""")
+ C.PI_NAME: "XEP 0095 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0095",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0095"],
+ C.PI_MAIN: "XEP_0095",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Stream Initiation""")
}
diff --git a/src/plugins/plugin_xep_0096.py b/src/plugins/plugin_xep_0096.py
index 348277b1..a4ba3d4d 100755
--- a/src/plugins/plugin_xep_0096.py
+++ b/src/plugins/plugin_xep_0096.py
@@ -35,14 +35,14 @@ SI_PROFILE_NAME = "file-transfer"
SI_PROFILE = "http://jabber.org/protocol/si/profile/" + SI_PROFILE_NAME
PLUGIN_INFO = {
- "name": "XEP-0096 Plugin",
- "import_name": "XEP-0096",
- "type": "XEP",
- "protocols": ["XEP-0096"],
- "dependencies": ["XEP-0020", "XEP-0095", "XEP-0065", "XEP-0047", "FILE"],
- "main": "XEP_0096",
- "handler": "no",
- "description": _("""Implementation of SI File Transfer""")
+ C.PI_NAME: "XEP-0096 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0096",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0096"],
+ C.PI_DEPENDENCIES: ["XEP-0020", "XEP-0095", "XEP-0065", "XEP-0047", "FILE"],
+ C.PI_MAIN: "XEP_0096",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Implementation of SI File Transfer""")
}
diff --git a/src/plugins/plugin_xep_0100.py b/src/plugins/plugin_xep_0100.py
index 78a0ec65..aabd6806 100755
--- a/src/plugins/plugin_xep_0100.py
+++ b/src/plugins/plugin_xep_0100.py
@@ -27,13 +27,13 @@ from twisted.words.protocols.jabber import jid
from twisted.internet import reactor, defer
PLUGIN_INFO = {
- "name": "Gateways Plugin",
- "import_name": "XEP-0100",
- "type": "XEP",
- "protocols": ["XEP-0100"],
- "dependencies": ["XEP-0077"],
- "main": "XEP_0100",
- "description": _("""Implementation of Gateways protocol""")
+ C.PI_NAME: "Gateways Plugin",
+ C.PI_IMPORT_NAME: "XEP-0100",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0100"],
+ C.PI_DEPENDENCIES: ["XEP-0077"],
+ C.PI_MAIN: "XEP_0100",
+ C.PI_DESCRIPTION: _("""Implementation of Gateways protocol""")
}
WARNING_MSG = D_(u"""Be careful ! Gateways allow you to use an external IM (legacy IM), so you can see your contact as XMPP contacts.
diff --git a/src/plugins/plugin_xep_0115.py b/src/plugins/plugin_xep_0115.py
index 3c95ebf0..ed8882c1 100755
--- a/src/plugins/plugin_xep_0115.py
+++ b/src/plugins/plugin_xep_0115.py
@@ -38,14 +38,14 @@ NS_CAPS_OPTIMIZE = 'http://jabber.org/protocol/caps#optimize'
CAPABILITY_UPDATE = PRESENCE + '/c[@xmlns="' + NS_ENTITY_CAPABILITY + '"]'
PLUGIN_INFO = {
- "name": "XEP 0115 Plugin",
- "import_name": "XEP-0115",
- "type": "XEP",
- "protocols": ["XEP-0115"],
- "dependencies": [],
- "main": "XEP_0115",
- "handler": "yes",
- "description": _("""Implementation of entity capabilities""")
+ C.PI_NAME: "XEP 0115 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0115",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0115"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: "XEP_0115",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of entity capabilities""")
}
diff --git a/src/plugins/plugin_xep_0163.py b/src/plugins/plugin_xep_0163.py
index a465cab6..0bdc7cf3 100755
--- a/src/plugins/plugin_xep_0163.py
+++ b/src/plugins/plugin_xep_0163.py
@@ -30,14 +30,14 @@ from wokkel.formats import Mood
NS_USER_MOOD = 'http://jabber.org/protocol/mood'
PLUGIN_INFO = {
- "name": "Personal Eventing Protocol Plugin",
- "import_name": "XEP-0163",
- "type": "XEP",
- "protocols": ["XEP-0163", "XEP-0107"],
- "dependencies": ["XEP-0060"],
- "main": "XEP_0163",
- "handler": "no",
- "description": _("""Implementation of Personal Eventing Protocol""")
+ C.PI_NAME: "Personal Eventing Protocol Plugin",
+ C.PI_IMPORT_NAME: "XEP-0163",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0163", "XEP-0107"],
+ C.PI_DEPENDENCIES: ["XEP-0060"],
+ C.PI_MAIN: "XEP_0163",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Implementation of Personal Eventing Protocol""")
}
diff --git a/src/plugins/plugin_xep_0166.py b/src/plugins/plugin_xep_0166.py
index ecae364e..37262010 100644
--- a/src/plugins/plugin_xep_0166.py
+++ b/src/plugins/plugin_xep_0166.py
@@ -48,13 +48,13 @@ STATE_ENDED = "ENDED"
CONFIRM_TXT = D_("{entity} want to start a jingle session with you, do you accept ?")
PLUGIN_INFO = {
- "name": "Jingle",
- "import_name": "XEP-0166",
- "type": "XEP",
- "protocols": ["XEP-0166"],
- "main": "XEP_0166",
- "handler": "yes",
- "description": _("""Implementation of Jingle""")
+ C.PI_NAME: "Jingle",
+ C.PI_IMPORT_NAME: "XEP-0166",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0166"],
+ C.PI_MAIN: "XEP_0166",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Jingle""")
}
diff --git a/src/plugins/plugin_xep_0184.py b/src/plugins/plugin_xep_0184.py
index 04113f14..8693f3e5 100644
--- a/src/plugins/plugin_xep_0184.py
+++ b/src/plugins/plugin_xep_0184.py
@@ -17,6 +17,7 @@
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
from twisted.internet import reactor
from twisted.words.protocols.jabber import xmlstream, jid
@@ -50,14 +51,14 @@ ENTITY_KEY = PARAM_KEY + "_" + PARAM_NAME
PLUGIN_INFO = {
-"name": "XEP-0184 Plugin",
-"import_name": "XEP-0184",
-"type": "XEP",
-"protocols": ["XEP-0184"],
-"dependencies": [],
-"main": "XEP_0184",
-"handler": "yes",
-"description": _("""Implementation of Message Delivery Receipts""")
+C.PI_NAME: "XEP-0184 Plugin",
+C.PI_IMPORT_NAME: "XEP-0184",
+C.PI_TYPE: "XEP",
+C.PI_PROTOCOLS: ["XEP-0184"],
+C.PI_DEPENDENCIES: [],
+C.PI_MAIN: "XEP_0184",
+C.PI_HANDLER: "yes",
+C.PI_DESCRIPTION: _("""Implementation of Message Delivery Receipts""")
}
diff --git a/src/plugins/plugin_xep_0203.py b/src/plugins/plugin_xep_0203.py
index 8f52346c..08201ccb 100644
--- a/src/plugins/plugin_xep_0203.py
+++ b/src/plugins/plugin_xep_0203.py
@@ -19,6 +19,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
@@ -33,13 +34,13 @@ from zope.interface import implements
NS_DD = 'urn:xmpp:delay'
PLUGIN_INFO = {
- "name": "Delayed Delivery",
- "import_name": "XEP-0203",
- "type": "XEP",
- "protocols": ["XEP-0203"],
- "main": "XEP_0203",
- "handler": "yes",
- "description": _("""Implementation of Delayed Delivery""")
+ C.PI_NAME: "Delayed Delivery",
+ C.PI_IMPORT_NAME: "XEP-0203",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0203"],
+ C.PI_MAIN: "XEP_0203",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Delayed Delivery""")
}
diff --git a/src/plugins/plugin_xep_0231.py b/src/plugins/plugin_xep_0231.py
index 1d25245f..d1328e0d 100644
--- a/src/plugins/plugin_xep_0231.py
+++ b/src/plugins/plugin_xep_0231.py
@@ -29,14 +29,14 @@ import base64
PLUGIN_INFO = {
- "name": "Bits of Binary",
- "import_name": "XEP-0231",
- "type": "XEP",
- "protocols": ["XEP-0231"],
- "dependencies": ["XEP-0071"],
- "main": "XEP_0231",
- "handler": "yes",
- "description": _("""Implementation of bits of binary (used for small images/files)""")
+ C.PI_NAME: "Bits of Binary",
+ C.PI_IMPORT_NAME: "XEP-0231",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0231"],
+ C.PI_DEPENDENCIES: ["XEP-0071"],
+ C.PI_MAIN: "XEP_0231",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of bits of binary (used for small images/files)""")
}
NS_BOB = u'urn:xmpp:bob'
diff --git a/src/plugins/plugin_xep_0234.py b/src/plugins/plugin_xep_0234.py
index f40c2718..ac0ab59b 100644
--- a/src/plugins/plugin_xep_0234.py
+++ b/src/plugins/plugin_xep_0234.py
@@ -38,14 +38,14 @@ from twisted.internet import error as internet_error
NS_JINGLE_FT = 'urn:xmpp:jingle:apps:file-transfer:4'
PLUGIN_INFO = {
- "name": "Jingle File Transfer",
- "import_name": "XEP-0234",
- "type": "XEP",
- "protocols": ["XEP-0234"],
- "dependencies": ["XEP-0166", "XEP-0300", "FILE"],
- "main": "XEP_0234",
- "handler": "yes",
- "description": _("""Implementation of Jingle File Transfer""")
+ C.PI_NAME: "Jingle File Transfer",
+ C.PI_IMPORT_NAME: "XEP-0234",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0234"],
+ C.PI_DEPENDENCIES: ["XEP-0166", "XEP-0300", "FILE"],
+ C.PI_MAIN: "XEP_0234",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Jingle File Transfer""")
}
diff --git a/src/plugins/plugin_xep_0249.py b/src/plugins/plugin_xep_0249.py
index bdae233f..2c52b45e 100755
--- a/src/plugins/plugin_xep_0249.py
+++ b/src/plugins/plugin_xep_0249.py
@@ -44,15 +44,15 @@ AUTOJOIN_NAME = "Auto-join MUC on invitation"
AUTOJOIN_VALUES = ["ask", "always", "never"]
PLUGIN_INFO = {
- "name": "XEP 0249 Plugin",
- "import_name": "XEP-0249",
- "type": "XEP",
- "protocols": ["XEP-0249"],
- "dependencies": ["XEP-0045"],
- "recommendations": [C.TEXT_CMDS],
- "main": "XEP_0249",
- "handler": "yes",
- "description": _("""Implementation of Direct MUC Invitations""")
+ C.PI_NAME: "XEP 0249 Plugin",
+ C.PI_IMPORT_NAME: "XEP-0249",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0249"],
+ C.PI_DEPENDENCIES: ["XEP-0045"],
+ C.PI_RECOMMENDATIONS: [C.TEXT_CMDS],
+ C.PI_MAIN: "XEP_0249",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Direct MUC Invitations""")
}
diff --git a/src/plugins/plugin_xep_0260.py b/src/plugins/plugin_xep_0260.py
index e771e0ae..ec99efea 100644
--- a/src/plugins/plugin_xep_0260.py
+++ b/src/plugins/plugin_xep_0260.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from sat.core import exceptions
@@ -37,15 +38,15 @@ except ImportError:
NS_JINGLE_S5B = 'urn:xmpp:jingle:transports:s5b:1'
PLUGIN_INFO = {
- "name": "Jingle SOCKS5 Bytestreams",
- "import_name": "XEP-0260",
- "type": "XEP",
- "protocols": ["XEP-0260"],
- "dependencies": ["XEP-0166", "XEP-0065"],
- "recommendations": ["XEP-0261"], # needed for fallback
- "main": "XEP_0260",
- "handler": "yes",
- "description": _("""Implementation of Jingle SOCKS5 Bytestreams""")
+ C.PI_NAME: "Jingle SOCKS5 Bytestreams",
+ C.PI_IMPORT_NAME: "XEP-0260",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0260"],
+ C.PI_DEPENDENCIES: ["XEP-0166", "XEP-0065"],
+ C.PI_RECOMMENDATIONS: ["XEP-0261"], # needed for fallback
+ C.PI_MAIN: "XEP_0260",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Jingle SOCKS5 Bytestreams""")
}
diff --git a/src/plugins/plugin_xep_0261.py b/src/plugins/plugin_xep_0261.py
index c894cad8..e593bcb1 100644
--- a/src/plugins/plugin_xep_0261.py
+++ b/src/plugins/plugin_xep_0261.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from wokkel import disco, iwokkel
@@ -34,14 +35,14 @@ except ImportError:
NS_JINGLE_IBB = 'urn:xmpp:jingle:transports:ibb:1'
PLUGIN_INFO = {
- "name": "Jingle In-Band Bytestreams",
- "import_name": "XEP-0261",
- "type": "XEP",
- "protocols": ["XEP-0261"],
- "dependencies": ["XEP-0166", "XEP-0047"],
- "main": "XEP_0261",
- "handler": "yes",
- "description": _("""Implementation of Jingle In-Band Bytestreams""")
+ C.PI_NAME: "Jingle In-Band Bytestreams",
+ C.PI_IMPORT_NAME: "XEP-0261",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0261"],
+ C.PI_DEPENDENCIES: ["XEP-0166", "XEP-0047"],
+ C.PI_MAIN: "XEP_0261",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Jingle In-Band Bytestreams""")
}
diff --git a/src/plugins/plugin_xep_0277.py b/src/plugins/plugin_xep_0277.py
index e2bd3a32..cf58f705 100755
--- a/src/plugins/plugin_xep_0277.py
+++ b/src/plugins/plugin_xep_0277.py
@@ -46,15 +46,15 @@ NS_COMMENT_PREFIX = '{}:comments/'.format(NS_MICROBLOG)
PLUGIN_INFO = {
- "name": "Microblogging over XMPP Plugin",
- "import_name": "XEP-0277",
- "type": "XEP",
- "protocols": ["XEP-0277"],
- "dependencies": ["XEP-0163", "XEP-0060", "TEXT-SYNTAXES"],
- "recommendations": ["XEP-0059", "EXTRA-PEP"],
- "main": "XEP_0277",
- "handler": "no",
- "description": _("""Implementation of microblogging Protocol""")
+ C.PI_NAME: "Microblogging over XMPP Plugin",
+ C.PI_IMPORT_NAME: "XEP-0277",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0277"],
+ C.PI_DEPENDENCIES: ["XEP-0163", "XEP-0060", "TEXT-SYNTAXES"],
+ C.PI_RECOMMENDATIONS: ["XEP-0059", "EXTRA-PEP"],
+ C.PI_MAIN: "XEP_0277",
+ C.PI_HANDLER: "no",
+ C.PI_DESCRIPTION: _("""Implementation of microblogging Protocol""")
}
diff --git a/src/plugins/plugin_xep_0280.py b/src/plugins/plugin_xep_0280.py
index 31f7e1de..30323ac9 100755
--- a/src/plugins/plugin_xep_0280.py
+++ b/src/plugins/plugin_xep_0280.py
@@ -39,14 +39,14 @@ PARAM_LABEL = D_(u"Message carbons")
NS_CARBONS = 'urn:xmpp:carbons:2'
PLUGIN_INFO = {
- "name": u"XEP-0280 Plugin",
- "import_name": u"XEP-0280",
- "type": u"XEP",
- "protocols": [u"XEP-0280"],
- "dependencies": [],
- "main": u"XEP_0280",
- "handler": u"yes",
- "description": D_(u"""Implementation of Message Carbons""")
+ C.PI_NAME: u"XEP-0280 Plugin",
+ C.PI_IMPORT_NAME: u"XEP-0280",
+ C.PI_TYPE: u"XEP",
+ C.PI_PROTOCOLS: [u"XEP-0280"],
+ C.PI_DEPENDENCIES: [],
+ C.PI_MAIN: u"XEP_0280",
+ C.PI_HANDLER: u"yes",
+ C.PI_DESCRIPTION: D_(u"""Implementation of Message Carbons""")
}
diff --git a/src/plugins/plugin_xep_0297.py b/src/plugins/plugin_xep_0297.py
index dad23d9a..ee8d6e0b 100644
--- a/src/plugins/plugin_xep_0297.py
+++ b/src/plugins/plugin_xep_0297.py
@@ -35,13 +35,13 @@ from twisted.words.xish import domish
NS_SF = C.NS_FORWARD
PLUGIN_INFO = {
- u"name": u"Stanza Forwarding",
- u"import_name": u"XEP-0297",
- u"type": u"XEP",
- u"protocols": [u"XEP-0297"],
- u"main": "XEP_0297",
- u"handler": u"yes",
- u"description": D_(u"""Implementation of Stanza Forwarding""")
+ C.PI_NAME: u"Stanza Forwarding",
+ C.PI_IMPORT_NAME: u"XEP-0297",
+ C.PI_TYPE: u"XEP",
+ C.PI_PROTOCOLS: [u"XEP-0297"],
+ C.PI_MAIN: "XEP_0297",
+ C.PI_HANDLER: u"yes",
+ C.PI_DESCRIPTION: D_(u"""Implementation of Stanza Forwarding""")
}
diff --git a/src/plugins/plugin_xep_0300.py b/src/plugins/plugin_xep_0300.py
index 63078dbb..6e7ce1c0 100644
--- a/src/plugins/plugin_xep_0300.py
+++ b/src/plugins/plugin_xep_0300.py
@@ -18,6 +18,7 @@
# along with this program. If not, see .
from sat.core.i18n import _
+from sat.core.constants import Const as C
from sat.core.log import getLogger
log = getLogger(__name__)
from sat.core import exceptions
@@ -32,13 +33,13 @@ import hashlib
PLUGIN_INFO = {
- "name": "Cryptographic Hash Functions",
- "import_name": "XEP-0300",
- "type": "XEP",
- "protocols": ["XEP-0300"],
- "main": "XEP_0300",
- "handler": "yes",
- "description": _("""Management of cryptographic hashes""")
+ C.PI_NAME: "Cryptographic Hash Functions",
+ C.PI_IMPORT_NAME: "XEP-0300",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0300"],
+ C.PI_MAIN: "XEP_0300",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Management of cryptographic hashes""")
}
NS_HASHES = "urn:xmpp:hashes:1"
diff --git a/src/plugins/plugin_xep_0313.py b/src/plugins/plugin_xep_0313.py
index ba3104ac..88b1ac01 100644
--- a/src/plugins/plugin_xep_0313.py
+++ b/src/plugins/plugin_xep_0313.py
@@ -39,13 +39,13 @@ from wokkel import mam
MESSAGE_RESULT = "/message/result[@xmlns='{mam_ns}' and @queryid='{query_id}']"
PLUGIN_INFO = {
- "name": "Message Archive Management",
- "import_name": "XEP-0313",
- "type": "XEP",
- "protocols": ["XEP-0313"],
- "main": "XEP_0313",
- "handler": "yes",
- "description": _("""Implementation of Message Archive Management""")
+ C.PI_NAME: "Message Archive Management",
+ C.PI_IMPORT_NAME: "XEP-0313",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0313"],
+ C.PI_MAIN: "XEP_0313",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of Message Archive Management""")
}
diff --git a/src/plugins/plugin_xep_0334.py b/src/plugins/plugin_xep_0334.py
index 5c5dc07e..96faf45f 100644
--- a/src/plugins/plugin_xep_0334.py
+++ b/src/plugins/plugin_xep_0334.py
@@ -35,14 +35,14 @@ from textwrap import dedent
PLUGIN_INFO = {
- "name": u"Message Processing Hints",
- "import_name": u"XEP-0334",
- "type": u"XEP",
- "protocols": [u"XEP-0334"],
- "main": "XEP_0334",
- "handler": u"yes",
- "description": D_(u"""Implementation of Message Processing Hints"""),
- "usage": dedent(D_(u"""\
+ C.PI_NAME: u"Message Processing Hints",
+ C.PI_IMPORT_NAME: u"XEP-0334",
+ C.PI_TYPE: u"XEP",
+ C.PI_PROTOCOLS: [u"XEP-0334"],
+ C.PI_MAIN: "XEP_0334",
+ C.PI_HANDLER: u"yes",
+ C.PI_DESCRIPTION: D_(u"""Implementation of Message Processing Hints"""),
+ C.PI_USAGE: dedent(D_(u"""\
Frontends can use HINT_* constants in mess_data['extra'] in a serialized 'hints' dict.
Internal plugins can use directly addHint([HINT_* constant]).
Will set mess_data['extra']['history'] to 'skipped' when no store is requested and message is not saved in history."""))
diff --git a/src/plugins/plugin_xep_0363.py b/src/plugins/plugin_xep_0363.py
index ff9e70fc..6be7b446 100644
--- a/src/plugins/plugin_xep_0363.py
+++ b/src/plugins/plugin_xep_0363.py
@@ -42,14 +42,14 @@ import mimetypes
PLUGIN_INFO = {
- "name": "HTTP File Upload",
- "import_name": "XEP-0363",
- "type": "XEP",
- "protocols": ["XEP-0363"],
- "dependencies": ["FILE", "UPLOAD"],
- "main": "XEP_0363",
- "handler": "yes",
- "description": _("""Implementation of HTTP File Upload""")
+ C.PI_NAME: "HTTP File Upload",
+ C.PI_IMPORT_NAME: "XEP-0363",
+ C.PI_TYPE: "XEP",
+ C.PI_PROTOCOLS: ["XEP-0363"],
+ C.PI_DEPENDENCIES: ["FILE", "UPLOAD"],
+ C.PI_MAIN: "XEP_0363",
+ C.PI_HANDLER: "yes",
+ C.PI_DESCRIPTION: _("""Implementation of HTTP File Upload""")
}
NS_HTTP_UPLOAD = 'urn:xmpp:http:upload'