Alexey Sokolov
fecdd98958
Add support SWIG 4.1.0, drop support for < 4.0.1
...
https://bugs.gentoo.org/878587
2022-11-05 13:02:12 +00:00
Alexey Sokolov
e0c05ddb63
Rename cmd/desc to command/description
...
Ref #1832
2022-07-04 23:16:22 +01:00
Ernestas Kulik
94f1c32729
modules: modpython: Implement Module.AddCommand()
...
Currently, there is no usable wrapper for CModCommand for use within
bindings, so this commit adds a proxy class that adds itself as a
callback and allows implementing Python classes to implement commands
via __call__().
A completely synthetic example:
import znc
class foo(znc.Module):
module_types = [znc.CModInfo.UserModule]
def OnLoad(self, args, message):
self.AddHelpCommand()
self.AddCommand(FooCmd)
return True
class FooCmd(znc.Command):
cmd = 'foo'
args = foo.t_d('bar')
desc = foo.t_d('baz')
def __call__(self, line):
self.GetModule().PutModule('I have been foo’d!')
Fixes https://github.com/znc/znc/issues/198
2022-07-04 07:28:24 +03:00
Falk Rund
6402d241ac
Welcome to 2022
...
The same procedure as last year, Miss Sophie?
Same procedure as every year, James.
2022-01-01 14:05:32 +01:00
MAGIC
99687b0f24
Welcome to 2021
2021-01-01 19:37:07 +01:00
Alexey Sokolov
47e633b267
Don't load modperl as a python module
...
Close #1757
2020-09-17 23:08:19 +01:00
Alexey Sokolov
b3b38956a7
Rewrite how modpython loads modules
...
'imp' was deprecated since python 3.3.
This removes the undocumented feature of loading python C extension as
ZNC module, but adds a test that python package can be loaded.
Bump python requirements to 3.4
2020-05-23 13:32:50 +01:00
Alexey Sokolov
dd42fcd209
Remove autoconf, leave only CMake
2020-05-01 23:44:19 +01:00
Alexey Sokolov
f3d7922499
Update copyright in files which were missing in the previous update
2020-01-05 11:37:51 +00:00
Alexey Sokolov
5b5ab5cf83
Support python 3.9
...
Fix #1702
2020-01-05 11:18:44 +00:00
MAGIC
9081aa971d
Welcome to 2020
2020-01-02 00:36:05 +01:00
Alexey Sokolov
960b76d2ea
Use FindPython3 in addition to pkg-config
2019-08-08 21:56:45 +01:00
Alexey Sokolov
0ab205ccfa
Merge pull request #1628 from dgw/welcome-to-2019
...
Welcome to 2019
2019-01-08 22:50:58 +00:00
dgw
8d5427cf9b
Welcome to 2019
...
What are we going to do today, Brain?
The same thing we do every year, Pinky: Update all the copyright
headers!
[Skip CI]
2019-01-01 17:05:05 -06:00
Pierre Gordon
6af027c5dd
Normalize methods with 'UserName' to 'Username'
2019-01-01 16:19:27 -05:00
Alexey Sokolov
8eebdf750d
Slightly cleaner way to fix #1543
2018-06-02 10:45:03 +01:00
Alexey Sokolov
11fb428878
Fix VCString return values in modpython
...
The list of functions which returned list of unknown objects instead of
list of strings:
* CMessage::GetParams()
* CZNC::GetMotd()
* CZNC::GetTrustedProxies()
* CZNC::GetBindHosts()
2018-06-02 01:02:40 +01:00
Alexey Sokolov
6eaa93f8da
Fix python sockets after latest changes.
...
The issue was triggered by CCoreTranslationMixin being parent of
CZNCSock, and DisableReadLine wasn't found as attribute anymore.
Thanks to obiw4n for report.
2018-03-27 22:26:05 +01:00
Falk Seidel
d647eaabc0
Welcome to 2018
...
The same procedure as last year, Miss Sophie?
The same procedure as every year, James.
[skip ci]
2018-01-19 19:38:58 +00:00
Alexey Sokolov
9474c3dc09
Support ValidateWebRequestCSRFCheck in perl/python. Fix #1424
2017-12-17 22:10:41 +00:00
Alexey Sokolov
ddd3023d5d
Refactor default return values of callbacks of perl/python modules
...
See #1424
2017-12-17 22:03:47 +00:00
Alexey Sokolov
7e94158c6d
More strings to translate #1354
2017-09-08 00:03:27 +01:00
MuffinMedic
74ab8e59d3
Add CQuery(s) and CServer(s) to modpython
2017-08-27 14:27:25 -04:00
Alexey Sokolov
ef5ace9b86
Travis: Also count code coverage of modpython
2017-05-28 08:52:37 +01:00
Alexey Sokolov
fa79f69be9
CMake: use pkg-config to find python.
...
Makes it easier to override its path.
2017-05-28 01:27:14 +01:00
Alexey Sokolov
18da03b66a
Fix clean cmake build again
...
8b48465df4 did it wrong
2017-04-30 15:01:45 +01:00
Alexey Sokolov
8b48465df4
Fix clean cmake build
2017-04-25 21:11:48 +01:00
Eli Young
823ac07240
Add OnSendToIRCMessage and OnSendToClientMessage
...
This also alters PutClient such that the CMessage variant handles
sending messages, rather than the CString variant. As a side bonus, this
gives callers better information on whether the message was sent to the
client. Additionally, it eliminates the need for a hook to let modules
set the tags sent to a client, as that can now be done inside
OnSendToClientMessage.
2017-04-18 15:43:16 -07:00
Phansa
3189ce7f8a
Welcome to 2017
...
Welcome to 2017
temp
temp2
2017-03-12 20:34:26 -04:00
Alexey Sokolov
455b5f8076
Merge branch '1.6.x'
2017-02-19 10:33:01 +00:00
Alexey Sokolov
0679957340
Fix regression of 1.6.4 which caused crash in modperl/modpython.
...
See #1283
2017-02-19 10:30:44 +00:00
Alexey Sokolov
4416ef9731
Add a TODO
...
[skip ci]
2017-01-12 00:08:48 +00:00
Alexey Sokolov
1bb0199ec4
Fix missing renames in #1191
2017-01-08 10:06:21 +00:00
Alexey Sokolov
2fcde9f2e1
Fix a couple of issues pointed out by https://scan.coverity.com/
2016-12-26 17:22:09 +00:00
Alexey Sokolov
ef6fb13ed2
Fix some modpython/modperl dependencies in cmake
2016-12-25 15:49:01 +00:00
Alexey Sokolov
c803a85e13
Rename new On...Message modules callbacks to be more consistent.
...
OnPrivMessage -> OnPrivTextMessage
OnChanMessage -> OnChanTextMessage
Fix #1191
2016-12-25 15:48:29 +00:00
Alexey Sokolov
106a36c22b
Rerun SWIG in CMake build when headers change.
2016-12-21 08:59:10 +00:00
Alexey Sokolov
cc653efb6b
Rename translation methods to be not one letter.
...
It fixes several warnings, when the name was shadowed by a local "p".
2016-09-12 00:01:45 +01:00
Alexey Sokolov
88a8675c80
Fix bad merge
2016-07-31 12:00:32 +01:00
Alexey Sokolov
05bf1c0f5e
Merge branch '1.6.x'
2016-07-31 10:37:38 +01:00
Alexey Sokolov
dd58e369f8
Fix OnInvite in modpython and modperl.
...
They were silently not called.
Close #1283
2016-07-31 10:35:19 +01:00
Alexey Sokolov
8863bed13d
Support translation in python modules
2016-01-31 20:09:19 +00:00
Alexey Sokolov
561a18054c
Yet another attempt to use CMake
2016-01-15 10:50:33 +00:00
Alexey Sokolov
89484acf17
Align #include in modperl/modpython with other files.
2016-01-10 09:12:17 +00:00
Falk Seidel
8f73840e74
Welcome to 2016
...
🎆 Happy 2016 🎆
2016-01-01 20:11:21 +01:00
Alexey Sokolov
d185d6f22d
clang-format: switch tabs to spaces
...
I like tabs, but I have to admit that spaces make source code more
consistent, because every editor/viewer tends to render tabs differently :(
2015-12-07 00:53:30 +00:00
Alexey Sokolov
33b0627d75
Add clang-format configuration.
...
For now, it uses tabs like before, to make the diff easier to read/check.
One of following commits will switch it to spaces.
2015-12-07 00:53:01 +00:00
Alexey Sokolov
cbf5c38d0a
Teach modperl and modpython about CMessage and new hooks which accept it.
...
Fix #1084
Fix #1085
2015-11-22 23:39:30 +00:00
Alexey Sokolov
4aba9fed17
Fix znc-buildmod on cygwin when installed to not /usr
...
1. Use import library, so don't require -L/bin anymore
2. Move -lznc from LDFLAGS to LIBS
3. Fix variables in znc-buildmod. It worked before only because
${exec_prefix} was resolving to empty string, and /bin == /usr/bin on
cygwin.
2015-08-22 12:42:28 +01:00
Alexey Sokolov
4b62962d2f
Merge branch '1.6.x'
2015-08-05 00:18:34 +01:00