2 new methods can be used:
- icon_defs to include definitions of svg icons
- icon to use one previously declared svg
plain svg is used instead of icon fonts to improve accessibility.
the version has not been changed to avoid too creating update for such a small change.
Even if generally a database change means a version change, this one has not be wide spreaded, and it will be updated automatically for dev version.
A manual "drop table files" using sqlite3 shell might clean things up though.
The reason of the column name change is that hash is named file_hash in code (because "hash" is a reserved word), and using the same name simplify data manipulation.
- file sending now handle --path and --namespace (used to specify how to share a file)
- implemented file request, a file must be identified by it's name or hash, using --path when possible
- added share subcommands
- share/list allows to list file shared by an entity at a specific path
- share/path allows one to share a local path privatly (only accessible by its bare jid), publicly or to a whitelist of jids
the plugin do an implementation for client and component.
For client, any directory from local file can be shared.
For component file are stored using new file handling mechanism from SàT.
Permission is handled, using "public" and "whitelist" for now.
huge patch sorry :)
many things are improved by this patch, notably:
- updated to last protocol changes (urn:xmpp:jingle:apps:file-transfer:5 and urn:xmpp:hashes:2)
- XEP-0234: file request implementation
- XEP-0234: methods to parse and generate <file> element (can be used by other plugins easily)
- XEP-0234: range data is now in a namedtuple
- path and namespace can be specified when sending/requesting a file (not standard, but needed for file sharing)
- better error/termination handling
- trigger points to handle file requests by other plugins
- preparation to use file plugins with components
- checkFilePermission check that requested permission(s) are granted for a file (without checking the parents)
- checkPermissionToRoot check that requested permission(s) are granted for a file and all its parents
- getFiles retrieve file(s) according to filter, and check permissions by default
- setFile create a file (and its parents if needed) and check permissions by default
/!\ new database schema version
- added a table to handle files metadata and hierarchy.
- new methods getFiles and setFile allow respectively to retrieve files corresponding to filters, and to set metadata for one file.
- fixed stmnt_regex to detect correcly new schema (during schema validation/update on init)
Normally trigger return value is a boolean used to check if normal workflow must be continued or stopped.
This method add a way to also specify a return value to the method, in addition to the "continue or not" boolean.
- renamed component boolean to is_component for more clarity
- profileConnected/profileDisconnected don't use a suffix anymore, it's called for both client and component.
To check for there, the is_component boolean is enough
- fixed dependencies handling
- componentStart is not mandatory anymore, as a component can just be used with its handler
- avoid crash when table is empty
- a column can now be hidden on display, this can be useful if one data is needed (e.g. to change color of an other column with a filter),
but we don't want to display it
- filters have a new argument with all data of a row (for the same reason as above, one column can be used to change display of other column)
this is a big patch as things had to be changed at the same time.
- changed methods using profile argument to use client instead
- move SatFile in a new tools.stream module, has it should be part of core, not a plugin
- new IStreamProducer interface, to handler starting a pull producer
- new FileStreamObject which create a stream producer/consumer from a SatFile
- plugin pipe is no more using unix named pipe, as it complicate the thing,
special care need to be taken to not block, and it's generally not necessary.
Instead a socket is now used, so the plugin has been renomed to jingle stream.
- bad connection/error should be better handler in jingle stream plugin, and code should not block anymore
- jp pipe commands have been updated accordingly
fix bug 237
Dode common in plugins using schema have been factorised in pubsub schema plugin, and filters users in tickets handling have been renamed in a more generic way and put there too.
"reporter*" fields in tickets have been renamed to "author*" as it is a more generic term which can be used elsewhere.
The use of new utils.partial function make easy the creation of simple plugins using schema.
new format (i.e. format after date limit has been reached) can now be specified.
0 can now be used for "auto_limit" to use last midnight as date limit.
A new "auto_day" format can be used as shortcut to use last midnight as date limit, short datetime for old format, and time only for new format.