[Geany-devel] get build command from a plugin

Dimitar Zhekov dimitar.zhekov at xxxxx
Mon Jan 30 18:13:26 UTC 2012


On Mon, 30 Jan 2012 14:08:59 +1100
Lex Trotman <elextr at gmail.com> wrote:

> > How can I $subject?
> 
> At the moment you can't officially access any of the build system from
> a plugin.

[::surprise::]

> Initially I exposed some of the build system (see comments starting /*
> * in build.h/c) but concerns were raised that this exposed the
> implementation so it was removed.

I don't see anything starting with /**, and there are lots of /* *...

> My attempts to proactively define an interface that does not expose
> any implementation structures was also rejected, so there is
> officially no way.

Hmmm... Have you tried something simple, like:

const gchar *build_get_command(ft, index, part)

Where:

ft = filetype | independent | exec
index = 0, 1, ...
part = label | command | workdir

rval = NULL if index is too big or some other argument is invalid.

Of course, it's not much different than the current build_get_*()
functions, but doesn't expose any build structures. And I guess
people will need the effective value, not some particular source.

> I guess you need to request the parts you need, and those will be
> exposed in the usual ad-hoc way.

Some home_ft/project specific commands. They're not hard to get, but
re-reading the key files is hardly the right thing.

-- 
E-gards: Jimmy



More information about the Devel mailing list