Hi,
Have had a think about this. As you know there's currently no way to
do the count guard with TMSU. One thought I've had for a while is
automatic tags based upon file meta-data so, for example, all files
might gain an automatic 'size' tag of the file-size as its value,
images may gain 'width' and 'height' tags, &c. Along those lines it
would be possible to have a dynamic 'tagCount' tag which describes how
many tags a file has that could then be used in queries.
I do worry this sort of stuff would put a large processing overhead on
queries, especially on large databases. For example, a query of
'tagCount == 3' would require either calculating, on the fly, the tag
count for every file or would have to be converted to the equivalent
SQL.
Regarding exact tag set matching, that sounds possible with the
addition of an '--exact' option to the 'files' subcommand, which
would instruct it only to match files that have the exact tags
specified. Is this a common scenario though? In what sort of
situations would one care that a file doesn't have, additionally,
other tags?
Finally limiting the queries to a set of specific files. This can be
done already using the --path option but it would have to be done on a
single path at a time (fine if your files are all under a directory
but not possible in a single invocation otherwise). I guess it would
be straightforward to add an option to match against a set of paths.
Again, in what situation is this useful?
Thanks,
Paul