It was <2013-07-12 pią 04:48>, when Kyungmin Park wrote:
> On Fri, Jul 12, 2013 at 7:43 AM, Lennart Poettering
> <lenn...@poettering.net> wrote:
>> On Thu, 11.07.13 13:37, Dave Reisner (d...@falconindy.com) wrote:
>>
>>> > +        p = strchr(path, ':');
>>>
>>> This is going to fail for a file:value pair such as /foo:/bar/baz:value.
>>> You could use strrchr(), but then you have to be concerned about
>>> matching values with a colon.
>>
>> This might become a problem, but then again, I think it is OK if some
>> files cannot be checked with this. I'd prefer using a space or "=" as
>> separator as a better choice though, as that's probably less frequent
>> than ":" in the names of files one would check with this condition
>> setting.
>>
>> Lennart
>>
>
> It's another question.
> the main goal of this patch is that supports conditional execution
> If some services are executed with given condition, it should check
> some conditions and execute different flow.
> if [ condition is 1 ]; then
>     launch A service
> else if [ condition is 2 ]; then
>     launch B service
> else
>     launch C service

IMHO this looks too complicated to fit into systemd units. To support
such (multiple choice) situation (which seems like the the conditions
are not properly stated) we can use a generator to link the desired
service to the proper target.

-- 
Łukasz Stelmach
Samsung R&D Institute Poland
Samsung Electronics
_______________________________________________
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to