tools/gstreamer-completion: Updated to work with the binary registry
authorDavid Rothlisberger <david@rothlis.net>
Tue, 13 Nov 2012 16:36:46 +0000 (16:36 +0000)
committerStefan Sauer <ensonic@users.sf.net>
Mon, 29 Apr 2013 19:12:42 +0000 (21:12 +0200)
commit271c707c45a7d46368eedba4f0d0539834b6a72a
tree581aa652fe67c70ea9d7522d979e3f3bbe43674e
parenta2170fc7b8b088bf52eef18e9faa48ddd1f11377
tools/gstreamer-completion: Updated to work with the binary registry

The original registry was in xml format (~/.gstreamer-*/registry.xml). A
binary registry format was added in 2007 (commit ebf0c9d3) and made the
default in 2008 (commit 3f39fd7e). In 0.10 you could still choose at
"configure" time to use the xml registry instead; in 1.0 the binary
registry is your only choice.

This change to gstreamer-completion should work with either format
because it parses the output of "gst-inspect" instead of reading the
registry file directly.

Note that _gst_launch no longer needs an explicit "return 0" because,
unlike the previous grep command, compgen always returns 0 (unless a
genuine error occurs).

Just like the previous implementation by David Schleef, this "only
completes names of features, but that's 90% of what I want it for."
tools/gstreamer-completion