From owner-freebsd-hackers@FreeBSD.ORG Sun Oct 19 00:53:39 2014 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id CB9C7A3F for ; Sun, 19 Oct 2014 00:53:39 +0000 (UTC) Received: from know-smtprelay-omc-1.server.virginmedia.net (know-smtprelay-omc-1.server.virginmedia.net [80.0.253.65]) by mx1.freebsd.org (Postfix) with ESMTP id 46A58FBF for ; Sun, 19 Oct 2014 00:53:38 +0000 (UTC) Received: from [192.168.1.100] ([86.20.122.200]) by know-smtprelay-1-imp with bizsmtp id 4osU1p00q4KXVwe01osUum; Sun, 19 Oct 2014 01:52:28 +0100 X-Originating-IP: [86.20.122.200] X-Spam: 0 X-Authority: v=2.1 cv=RcseCjdv c=1 sm=1 tr=0 a=WByauD8lJrWvBFCNrxRoEQ==:117 a=WByauD8lJrWvBFCNrxRoEQ==:17 a=TlgFaoZnv2EA:10 a=uObrxnre4hsA:10 a=8nJEP1OIZ-IA:10 a=NLZqzBF-AAAA:8 a=JjLgQdwQY_S_jpjqNbAA:9 a=bwXatPVJ6H-v4hfr:21 a=fReGTqKZwTuZqI_N:21 a=wPNLvfGTeEIA:10 a=XdyKOaxJwVsA:10 Message-ID: <54430B41.3010301@NTLWorld.com> Date: Sun, 19 Oct 2014 01:52:17 +0100 From: Jonathan de Boyne Pollard User-Agent: Mozilla/5.0 (Windows NT 6.0; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 MIME-Version: 1.0 To: FreeBSD Hackers Subject: nosh version 1.9 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Sun, 19 Oct 2014 01:19:28 +0000 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 19 Oct 2014 00:53:39 -0000 nosh version 1.9 is out. If you've not heard of it, here's the blurb: * http://homepage.ntlworld.com./jonathan.deboynepollard/Softwares/nosh.html If you also read the worked example, make sure that you read all of the way to the bottom. (-: If you want to read more, there's a whole Guide in the package, and lots of manual pages. There's now a command for converting FreeBSD /etc/rc.conf{,.local} preset information (the *_enable variables) to service bundle preset information. For kicks, I've also added a small shim for the OpenBSD "rcctl" command that they're busy inventing. It's worth noting that OpenBSD 5.6 now specifies that /etc/rc.conf{,.local} doesn't have shell expansions and isn't necessarily sourced by a shell, which is change that I welcome with open arms. I will be looking at conversion of OpenBSD *_flags variables; but the big thing that remains in this area is a utility that pushes all of the other variables, apart from *_enable, into envdirs in the appropriate service bundles, which is going to be a tedious one-by-one slog because sometimes the variable names don't match the service names, as you no doubt know. I set myself a task of converting to service bundles all but two of the 157 non-target scripts that I found in a stock FreeBSD /etc/rc.d/ . I've reached 85. A lot of the remaining scripts are complex, often one-shot, shell scripts onto the side of which the rc.d start/stop system has been bolted, with varying degrees of success. If you are interested in helping, one of the things that would help greatly is factoring out the meat of some of these into helper commands of some kind, reducing the lopsided hulks to something more like (say) /etc/rc.d/rpcbind . (I can supply a list.) As reciprocal payment in advance, I'm letting you know that /etc/rc.d/msgs is missing all of the rc.d mechanism, and so does the same thing on every start/stop/restart/whatever command verb. Although I suggest that factoring out things in this way is a gain for the rc.d system, too, and of mutual benefit.