def GenInit(svc, desc, start=('2', '3', '4', '5'), stop='1'):
 insserv = '\n    $local_fs   +umountfs\n    $network    +networking\n    $remote_fs  $local_fs +umountnfs +sendsigs\n    $syslog     +rsyslog +sysklogd +syslog-ng +dsyslog +inetutils-syslogd\n    '
 tmpl = ('\n    ### BEGIN INIT INFO\n    # Provides:             %s\n    # Required-Start:       $remote_fs $syslog\n    # Required-Stop:        $syslog\n    # Default-Start:        %s\n    # Default-Stop:         %s\n    # Short-Description:    %s\n    ### END INIT INFO\n    ' % (svc, ' '.join(start), ' '.join(stop), desc))
 return {'/etc/insserv.conf': insserv, ('/etc/init.d/%s' % svc): tmpl}

def GenInit ( svc , desc , start = ( '2' , '3' , '4' , '5' ) , stop = '1' ) : insserv = '\n    $local_fs   +umountfs\n    $network    +networking\n    $remote_fs  $local_fs +umountnfs +sendsigs\n    $syslog     +rsyslog +sysklogd +syslog-ng +dsyslog +inetutils-syslogd\n    ' tmpl = ( '\n    ### BEGIN INIT INFO\n    # Provides:             %s\n    # Required-Start:       $remote_fs $syslog\n    # Required-Stop:        $syslog\n    # Default-Start:        %s\n    # Default-Stop:         %s\n    # Short-Description:    %s\n    ### END INIT INFO\n    ' % ( svc , ' ' . join ( start ) , ' ' . join ( stop ) , desc ) ) return { '/etc/insserv.conf' : insserv , ( '/etc/init.d/%s' % svc ) : tmpl }
generate init file .