squishy

Sat, 14 Nov 2020 15:30:35 +0100

author
Kim Alvefur <zash@zash.se>
date
Sat, 14 Nov 2020 15:30:35 +0100
changeset 132
3addfb97296c
parent 122
1dfd28db10bd
child 139
6909e479c56b
permissions
-rw-r--r--

clix.raw: Add a shorthand for top level stanza attributes

The m, p and iq functions are amended so that indexing them sets the
'type' attribute and a subsequent function call with a string sets the
'to' attribute.

Examples:

m.chat"recipient":body"Hello"

iq.get"example.com":query"jabber:iq:version"

local commands = {
	"send";
	"sendfilecontent";
	"receive";
	"version";
	"ping";
	"bounce";
	"mirror";
	"raw";
	"roster";
	"export";
	"vcard";
	"publish_atom";
	"sendfile";
	"archive";
	"presence";
}

for _, cmd in ipairs(commands) do
	Module("clix."..cmd)("clix/"..cmd..".lua")
end

if GetOption "with-verse" then
	Module("verse")(GetOption "with-verse");
end

Main "clix.lua"

Option "executable"
Output "clix.bin"

mercurial