Path: utzoo!mnetor!uunet!lll-winken!lll-tis!ptsfa!pacbell!att-ih!alberta!calgary!xenlink!theo From: theo@xenlink.UUCP (Theo deRaadt) Newsgroups: comp.sys.amiga Subject: Re: Ban the Cloud! (plus sugg. for Workbench) Message-ID: <209@xenlink.UUCP> Date: 7 Mar 88 06:08:19 GMT References: <318@jc3b21.UUCP> <43704@sun.uucp> <727@sandino.quintus.UUCP> Organization: Xenlink 286 Lines: 44 Summary: program knows it's environment? In article <727@sandino.quintus.UUCP>, pds@quintus.UUCP (Peter Schachte) writes: > o To get REALLY fancy with this idea, allow a file (or it's .icon) > to specify methods for opening, writing a buffer to, reading a > buffer from, seeking in, etc., that file. This would allow some > really WONDERFUL things, e.g., files to be stored in compressed > form, but still be read and written by ordinary programs oblivious > to the storage technique. Or source code files could be stored in > pre-parsed format, and be greped, printed, etc., as usual, but > editors and compilers could have special knowledge about reading > them in as pre-parsed files. The possibilities are endless. I > know it sounds pretty radical, but I have some ideas on how to > implement it. I think it could make the Amiga about the > best-integrated microcomputer environment going. > -Peter Schachte > pds@quintus.uucp > ...!sun!quintus!pds I was wondering about something almost the same, but in shell files, since I still think that shell has a place in the world. I think that we need some way of specifying what execution environment a program is supposed to run in. Take Unix for example. If the first 2 bytes work out to "#!" it will parse the rest of that line for a program name, and pipe (maybe -c it?) the rest of the file into that program. [ for non-Unix types, #!/bin/sh shell commands... will run /bin/sh and make it read this file, and execute it. ] This seems like something that we could use, in a future release. A friend who is more familiar with ADOS says that this could be built in by having another '#!' hunk? Matt, or a DOS person, care to comment? Does this sound reasonable? Makes running special programs a lot easier. I can just see it now, a makefile that starts out with #!make..... apply the same to C source, and a simple program that compiles from it's stdin, and then executes the output. :-) Sorry.. that's just too weird. I think that the point I am trying to establish is, that this could be used so that various shell scripts of ANY type, could run in ANY environment. The file would know it's environment. ----------------------------------------------------------------------------- Theo de Raadt. ..!ihnp4!alberta!calgary!xenlink!theo -----------------------------------------------------------------------------