Scripted plugins

Ray Strode halfline at gmail.com
Thu May 7 10:47:40 PDT 2009


Hi,

On Wed, May 6, 2009 at 6:41 PM, Charlie Brej <plymouth at brej.org> wrote:
> Just to keep everyone updated. I was meaning, over the new year, to create a
> scripting language to allow elements of the theme to be described. I got
> distracted half way though but just got back to it. I have currently got it to
> execute expressions so we can set the plugin variables (like the ones Ray allows
> to be set using the .plymouth files) to values which are not constant.
...
> I should have something to that effect by tomorrow afternoon, but ultimately
> what I was hoping to do is to allow the script to specify the images (dealing
> with strings), their placement, their movement/transformations etc.
It's an interesting idea for sure.

So I guess the point is to make writing splash themes easier?

> Thanks to the separation of themes and plugins what I was hoping to make is a
> single plugin called something like "scriptable" and have multiple themes which
> define their custom behaviours.
Right, makes sense.  Especially initially.  You could make a theme like:

[Plymouth Theme]
Name=Flashy Theme
Description=A flashy theme
ModuleName=scriptable

[scriptable]
ScriptFile=/usr/share/themes/plymouth/flashy/flashy.scriptable

The idea, in general, seems like a cool one.  One thing I like about
it is it lets theme writers create their themes without being
proficient in C.

I'm a little worried about the extra complication caused by plymouth
growing its own one-off scripting language.  If you do this, I guess
I'd recommend you keep it very simple.

I guess at the end of the day the thing that matters most is the end
product (for whatever product plymouth is being deployed to).  The
pluggable splashes are really just an implementation detail to make it
easier to create those end products.  Making splashes should be easy,
but the code around the splashes should be small, too.  We don't want
the initrd to get too big, and we don't want plymouth to be hard to
debug.

This is definitely an interesting experiment, though. I'd really like
to see how it turns out.  Are you planning on working on a branch
eventually?  Or are you going to keep this out of tree until it's
ready to be merged?

--Ray


More information about the plymouth mailing list