Tool to parse systemd unit files

Trek trek00 at
Fri Nov 15 05:42:21 GMT 2019

I have updated my script to convert systemd services to init-d-script

there are 4 examples included, to better understand its output

it works fine with basic services, even if some verbs are ignored

it is intended to help maintainers to convert service files and it
cannot work (yet) without human supervision, as there are some glitches
with complex services

changes since the previous version:
- full conformance to unit file format, including lines ending with '\'
- service types support (but not idle and dbus)
- exec prefixes support (but not '@')
- dependency handling (via LSB)

I'm pretty satisfied by the actual script as it fits my needs, but tell
me if you find it useful or if you need some feature to be implemented

@sysvinit maintainers: I found a bug in init-d-script, as the status
command ignores the PIDFILE, fixed with the attached patch

@Lorenz: I think a runit output could be easily implementable or at
least the read_unit parsing function could be used directly in your
scripts, as it sets variables like: $ini_service_execstart

-------------- next part --------------
A non-text attachment was scrubbed...
Name: init-d-script-fix-status.patch
Type: text/x-patch
Size: 400 bytes
Desc: not available
URL: <>

More information about the Debian-init-diversity mailing list