sysinstall as a post-install tool

Devin Teske devin.teske at fisglobal.com
Wed Jan 4 04:08:08 UTC 2012


On Jan 3, 2012, at 7:30 PM, Eitan Adler wrote:

> On Tue, Jan 3, 2012 at 10:14 PM, Devin Teske <devin.teske at fisglobal.com> wrote:
>> host-setup actually leverages the power and safety of my sysrc(8) utility
>> (just added to ports tree as sysutils/sysrc).
>> 
>> In fact, sysrc was written as a test-script solely to feed back into
>> host-setup so that we could replace sysinstall's Configure menu. We're just
>> not there with all the menu items (but we've got the most important ones --
>> IMHO -- and made them rock-stable).
> 
> I want to see these tools in the base system.

I should mention one more tool that plays into all this... tzdialog.

Part of the puzzle to completing our quest of "replacing sysinstall" involved rewriting tzsetup(8). Largely because we had written host-setup(1) to work with Xdialog(1) and therefore thought that it would be better to have a tzsetup(8) that also supported Xdialog(1) rather than launching it within an xterm(1) (which was not-so-nice, but does work).

In rewriting tzsetup(8) to produce tzdialog(1), I strived _very_ hard to actually make it so that you can literally line up the C-code with the sh(1)-code. Picking out comments that are word-for-word the same is one thing, but re-using variable names and even going as far as to invent struct-analogs with the same names is another story. All the sh(1)-code follows the exact same logic as the C-code. When the C-code opens the ISO-3166 table from NIST and parses-out the data it needs, so does the sh(1)-code. Line-for-line, we try to mimic the C-code for the express purpose that we can perhaps replace tzsetup(8), but I'll let you be the judge.

I mention all this, because host-setup(1) will automatically pick-up on the existence of tzdialog(8) and prefer it as a drop-in replacement for tzsetup(8), should tzdialog(8) be installed and available. Thus, achieving the ability to actually set the time-zone via host-setup from a menu-item configured in a window manager or display manager (HINT: We've got our fvwm2 configuration configured with "exec host-setup -sX" which correctly hands-off the "-X" flag to tzdialog).

I haven't yet tossed the idea out there yet for creating a port for tzdialog(8) -- this is the first that I'm suggesting -- but since I'm going to make a request to submit host-setup(8), I'd figure I ought to make a request for tzdialog too, since the former can take advantage of the latter if/when installed.
-- 
Devin

Links:
http://druidbsd.sourceforge.net/
http://druidbsd.sourceforge.net/download/tzdialog.txt

_____________
The information contained in this message is proprietary and/or confidential. If you are not the intended recipient, please: (i) delete the message and all copies; (ii) do not disclose, distribute or use the message in any manner; and (iii) notify the sender immediately. In addition, please be aware that any message addressed to our domain is subject to archiving and review by persons other than the intended recipient. Thank you.


More information about the freebsd-sysinstall mailing list