[Tracker] Migrating tracker-utils/ into one 'tracker' command



Hi all,

So I spent some time last week working on this. I said in some earlier conversations with the maintainers that I would like to take things back to basics a bit using a more "git" like approach to tracker so it becomes more powerful on the command line.


Branch?
-------
As part of this, I wanted to merge the command line utils binaries into one binary in much the same way that Git does.

I have started a branch called "tracker-cmd" here:

  https://git.gnome.org/browse/tracker/log/?h=tracker-cmd

It works quite well and also has bash completion available:

  trac


Anything left to do?
--------------------
I have plans to later add some new commands like:

  $ tracker add /path/to/dir/to/index /another/path ...

and

  $ tracker rm /path/to/remove/from/index /and/another ...

Which would update the tracker-miner-fs config...

I've even been thinking about having something like:

  $ tracker show {extractors|supported-mime-types|...}

Or something like that, mainly because these are the commonly asked things when debugging or when trying to understand what Tracker is using to build the index in the first place.

I would like to know from those of you out there using Tracker in projects, what you think is missing from the command line tools to make life easier? Chances are, we can easily add what you need.

I may also integrate the utils/tracker-resdump/tracker-resdump code into one of the existing tracker commands.


Examples of what you can do now
-------------------------------
To give you some idea of what this branch already does, here's some examples of the newer work....:

*daemon* (previously from tracker-control):

  $ tracker daemon -s | -t [daemons] | -k [daemons] | -l
  $ tracker daemon -f | -w [ontology]
  $ tracker daemon --miner <miner> --pause[-for-process] <reason>
  $ tracker daemon --miner <miner> --resume <cookie>

*index* (previously from tracker-control):

  $ tracker index --reindex-mime-type <mime1> [[-m [mime2]] ...]
  $ tracker index --file <file1> [[file2] ...]
  $ tracker index --import <file1> [[file2] ...]
  $ tracker index --backup <file> | --restore <file>

*reset* (previously from tracker-control):

  $ tracker reset [--hard | --soft] [--config]

*sql* (previously utils/tracker-sql/tracker-sql):

  $ tracker sql -q <sql> | -f <file>

All other commands like tracker-sparql, tracker-info, tracker-tag, etc have been merged too of course, e.g.:

  $ tracker sparql -q <sparql> [-u] | -f <file>
  $ tracker sparql -t [class] [-s <needle>] [-p]
$ tracker sparql [-c] [-p] [-x] [-n [class]] [-i [property]] [-s <needle>]
  $ tracker sparql [--get-longhand <class>] [--get-shorthand <class>]


Comments appreciated!

--
Regards,
Martyn

Founder & Director @ Lanedo GmbH.
http://www.linkedin.com/in/martynrussell


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]