Fix RC out

This commit is contained in:
Lorenz Meier
2015-07-31 12:17:31 +02:00
parent 021417703f
commit 50a9e41dbd
+2 -3
View File
@@ -30,17 +30,16 @@ class RCOutput():
for group in groups: for group in groups:
result += "# GROUP: %s\n\n" % group.GetName() result += "# GROUP: %s\n\n" % group.GetName()
for param in group.GetParams(): for param in group.GetParams():
name = param.GetName()
path = param.GetPath().rsplit('/', 1)[1] path = param.GetPath().rsplit('/', 1)[1]
id_val = param.GetId() id_val = param.GetId()
name = param.GetFieldValue("short_desc") name = param.GetFieldValue("short_desc")
long_desc = param.GetFieldValue("long_desc") long_desc = param.GetFieldValue("long_desc")
result += "#\n" result += "#\n"
result += "# %s\n" % name result += "# %s\n" % param.GetName()
result += "if param compare SYS_AUTOSTART %s\n" % id_val result += "if param compare SYS_AUTOSTART %s\n" % id_val
result += "then\n" result += "then\n"
result += " sh /etc/init.d/%s\n" % path result += "\tsh /etc/init.d/%s\n" % path
result += "fi\n" result += "fi\n"
#if long_desc is not None: #if long_desc is not None: