Commit graph libervia-backend/src/plugins/plugin_misc_text_commands.py
Author SHA1 Message Date
Goffi
8ce5c1862b core, frontends: refactoring to base Libervia on QuickFrontend (big mixed commit):
/!\ not finished, everything is still instable !
    - bridge: DBus bridge has been modified to allow blocking call to be called in the same way as asynchronous calls
    - bridge: calls with a callback and no errback are now possible, default errback log the error
    - constants: removed hack to manage presence without OrderedDict, as an OrderedDict like class has been implemented in Libervia
    - core: getLastResource has been removed and replaced by getMainResource (there is a global better management of resources)
    - various style improvments: use of constants when possible, fixed variable overlaps, import of module instead of direct class import
    - frontends: printInfo and printMessage methods in (Quick)Chat are more generic (use of extra instead of timestamp)
    - frontends: bridge creation and option parsing (command line arguments) are now specified by the frontend in QuickApp __init__
    - frontends: ProfileManager manage a more complete plug sequence (some stuff formerly manage in contact_list have moved to ProfileManager)
    - quick_frontend (quick_widgets): QuickWidgetsManager is now iterable (all widgets are then returned), or can return an iterator on a specific class (return all widgets of this class) with getWidgets
    - frontends: tools.jid can now be used in Pyjamas, with some care
    - frontends (XMLUI): profile is now managed
    - core (memory): big improvment on entities cache management (and specially resource management)
    - core (params/exceptions): added PermissionError
    - various fixes and improvments, check diff for more details
2015-01-24 01:00:29 +01:00
Matteo Cypriani
71e29f5c44 misc: fixed some typos 2014-09-15 14:18:25 +02:00
Goffi
a20e3e2cb8 core: a new "info" type is used in newMessage for system messages (not comming from outside) 2014-09-05 19:29:30 +02:00
souliane
56ec86b8e5 plugin XEP-0045, text_commands: add some commands:
- handle generic failure in text_commands
    - fix command /leave and a logging message
    - add commands /kick /ban /affiliate
2014-06-23 15:42:56 +02:00
Goffi
87b3e413ee core (XMPP): sendMessage refactoring:
- better separation of message sending actions
    - use of more generic exceptions to hook the behaviour (SkipHistory and CancelError)
    - use of raise instead of return
    - use of failure.trap
2014-06-07 16:35:29 +02:00
Goffi
a3f460d391 plugin text commands: added /me command to avoid the need to escape the / 2014-05-15 19:51:53 +02:00
souliane
42b1b6c4ed plugins TEXT-COMMANDS, XEP-0045, XEP-0048, XEP-0249:
- give a feedback instead of sending the message when the command is invalid or used in a wrong context
    - add command /join for XEP-0249
2014-04-30 16:34:09 +02:00
Goffi
501bc92528 core: use of the new core.log module:
/!\ this is a massive refactoring and was largely automated, it probably did bring some bugs /!\
2014-04-19 19:19:19 +02:00
Goffi
90fc3d78e0 plugin text commands: commands are now sorted in /help 2014-03-24 15:18:53 +01:00
Goffi
b826dd7c10 plugin XEP-0045: added user information to /whois text command 2014-03-24 14:46:18 +01:00
Goffi
9ac686c0a9 plugin text-commands: fixed name conflicts management + plugin parrot: removed now done TODO 2014-03-24 13:49:37 +01:00
Goffi
8a52f6defa plugin text commands: refactoring, text now only contain main commands, and other plugin can add commands themselve:
- registerTextCommands can be called by a plugin in its __init__ method, it looks for methods starting with "cmd_" and register them as new commands
    - addWhoIsCb: add a callback to /whois command, the callback can complete whois informations
    - plugins parrot, XEP-0045 and XEP-0092 now manage their own commands
2014-03-24 10:57:15 +01:00
Goffi
93826f1ce8 core: sendMessageTrigger now manage pre and post treatments, which happen before or after XML generation 2014-03-22 15:34:05 +01:00
Goffi
bd3890a8f0 plugin text commands: refactoring:
- commands can now return a deferred
    - if commands return True, message is sent, else it is cancelled
    - the escape sequence is now '//' instead of '\/'
    - added software version to /whois command
2014-03-22 13:47:33 +01:00
Goffi
2ca6efd8cc dates update 2014-02-04 18:32:49 +01:00
Goffi
5a00dc9503 core: i18n refactoring:
- _() is no more installed in __builtin__
    - instead, there is a new sat.core.i18n module
    - added D_() method for deferred translation
    - languageSwitch method allow to dynamically change translation language
    - import gettext is tested against ImportError, and dummy methods are used when not available (mainly useful for Libervia)
2013-12-29 17:06:01 +01:00
Goffi
9d42c269db core: sendMessage's options parameter has been renamed to extra to be consistent with newMessage 2013-11-13 13:58:10 +01:00
Goffi
60f03a623e core: sendMessage triggers now use a treatments deferred;
- treaments deferred can be used by plugins to change XML elements before sending them, in a similar way as for newMessage
    - sendMessageXml trigger became useless, so it as been removed in favor of the new deferred
2013-11-13 13:57:36 +01:00
Goffi
1cd98e8dea fixed licences in docstrings (they are now in comments) 2013-03-08 00:36:22 +01:00
Goffi
f9ef9a4f4a plugin text commands: basic /whois command (just show jid so far) 2013-02-20 20:37:17 +01:00
Emmanuel Gil Peyrot
0dca274360 Fix pep8 support in src/plugins. 2013-01-18 17:55:35 +01:00
Emmanuel Gil Peyrot
88074cd284 Remove every old-style class. 2013-01-18 17:55:35 +01:00
Emmanuel Gil Peyrot
27b3592e16 Remove trailing whitespaces. 2013-01-18 17:55:34 +01:00
Goffi
def79e44cd dates update 2013-01-07 23:30:13 +01:00
Goffi
c2713681a3 plugin text commands: added /topic as a synonym of /title 2013-01-07 00:56:13 +01:00
Goffi
20815b3ec5 bridge: fixed D-Bus warning in frontend side of bridge 2012-11-01 19:52:59 +01:00
Goffi
225d3ac5f1 plugin text commands: added /parrot and /unparrot commands to use Parrot plugin
- /parrot command add parrot link between the current entity/room and the entity given as an argument (must be a valid jid)
    - similarly, /unparrot remove the 2 links between those entities.
    - Parrot is a new dependency of text commands
2012-10-21 19:46:08 +02:00
Goffi
9612fe6f75 plugin text commands: added _feedback method to send an answer to user 2012-10-21 13:37:15 +02:00
Goffi
72da42f762 reverted bad commit 2012-10-21 12:55:27 +02:00
Goffi
031bd3134f primitivus: fixed messages order in chat window 2012-10-21 12:03:29 +02:00
Goffi
8d34cacc1d plugin text commands: added /help command 2012-10-20 19:22:51 +02:00
Goffi
902045e174 plugin XEP-0045, plugin text commands: added '/title' command 2012-10-20 18:02:14 +02:00
Goffi
4225b694d0 plugin text commands: added /join command 2012-09-28 00:48:52 +02:00
Goffi
d75b24427e plugin text commands: /leave management:
- _getRoomJid manage room jid argument: the argument can be full jid or a shortcut.
      in case of shortcut, room or room@ can be used for shortcut room@service.domain.tld where service.domain.tld is the same as the one of the room where the command is entered
    - /leave alone leave the current room, /leave [room] leave the given room
	- /part is a synonym of /leave
2012-09-28 00:31:10 +02:00
Goffi
4e40bead7c plugin text commands: Text commands is a new plugin that bring IRC-like commands
- Text commands catch message sent, and check commands starting by /
	- /nick command is managed
2012-09-27 00:54:42 +02:00