Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 01 Feb 1999 00:49:58 +0900
From:      "Daniel C. Sobral" <dcs@newsguy.com>
To:        Mike Smith <mike@smith.net.au>
Cc:        Patrick Hartling <mystify@friley-184-92.res.iastate.edu>, freebsd-current@FreeBSD.ORG
Subject:   Re: Reading a text file with BTX
Message-ID:  <36B47BA6.AA940054@newsguy.com>
References:  <199901311502.HAA06566@dingo.cdrom.com>

next in thread | previous in thread | raw e-mail | index | archive | help
I'd like to suggest that nobody depends on the exact syntax below.
Using "@" at the beginning of the lines is EVIL, and has to go away.
Well, for *this* purpose, at least. Likewise, - at the beginning of
the line is also very evil. Very, very evil.

I have now, at last, a fully working version of "include" for forth
source code. With that, we are finally able to actually *use* ficl
in loader.rc and the likes. The down side, of course, is that we
ought to stop treating things included as special cases of "builtin
only" with special semantics. We get more power, but a few
concessions must be mude. Specifically, "@", "#" and "-".

Mike Smith wrote:
> 
> Perhaps try something like:
> 
> @set kernelname=kernel
> @read -t 5 -p "Enter kernel name [kernel] : " kernelname
> @load $kernelname
> @include /boot/modules.default
> -include /boot/modules.$kernelname
> @autoboot 5
> 
> The 'include' commands make it easier to keep your module sets
> organised, should you want to do that.

And include is also recursive. Or, at least, it should be. :-) There
is something smelly with the way errors are being treated, though it
might not show up in the current version because it's recursive
chain doesn't include bf_run().

Anyway, the above could be coded like this in my current version of
loader:

\ loader.rc
\ <-- This is the new character for comments
set kernelname=kernel			\ Don't echo is now default
read -t 5 -p "Enter kernel name [kernel] : " kernelname
load ${kernelname}			\ I thought {} was required
include /boot/modules.default
~ include /boot/modules.$kernelname	\ And this is the new way 
					\ of ignoring errors
autoboot 5

But the bottom line is that @#- are evil and must go away. :-) I
even thought of preemptively removing then from loader.help, so
nobody would get used to them... :-)

--
Daniel C. Sobral			(8-DCS)
dcs@newsguy.com

	Would you mind not shooting at the thermonuclear weapons?



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?36B47BA6.AA940054>