Hi there - I'm currently building a configuration system based on execline (I hope to have something to demonstrate soon) and I am familiarizing myself with the wider suite of execline-related tools, many of which are found in s6/66.

Specifically I am trying to understand the purpose of the "execl-cmdline" tool - it looks like it will be useful for some instances where I need to run a block directly from a substituted variable (instead of passing the entirety of it to a script which then runs "runblock" from positional parameters). Is this its main use case? Why is it used in 66 frontend scripts?

Thanks!
execlineb do not deal with empty word, so a command like
/usr/bin/ntpd -d "" -S
will crash cause of the empty word. execl-cmdline make the same command line to this
/usr/bin/ntpd -d -S
So, it remove the empty word. Also, the -s options split a quoted arguments into separated word like
/usr/bin/ntpd "-d -S"
become
/usr/bin/ntpd "-d" "-S"
Well, taking concrete example. 66 deal with environment file define by a user. Let's say we have an environment file containing this
cmd_args=-d  -S
with 2 space between the options, the service without execl-cmdline will crash due of the no word entry.

Hope i'm clear.

Powered by Obarun