Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!seismo!gatech!bloom-beacon!husc6!cmcl2!brl-adm!adm!rbj@icst-cmr.arpa From: rbj@icst-cmr.arpa (Root Boy Jim) Newsgroups: comp.unix.wizards Subject: symbolic links and csh execution Message-ID: <8305@brl-adm.ARPA> Date: Wed, 15-Jul-87 18:25:08 EDT Article-I.D.: brl-adm.8305 Posted: Wed Jul 15 18:25:08 1987 Date-Received: Sat, 18-Jul-87 00:36:46 EDT Sender: news@brl-adm.ARPA Lines: 37 From: Jonathan ClarkOn a similar note, for the people who are expounding starting one's shell scripts with "#! /bin/csh", the logical continuation of this is to start one's C programs with "#! /bin/cc", and so on. Hey, why not? This is more inline with the philosophy of `object oriented programming'. There already exist tools floating around the net to pick out embedded execution lines in text. Think about it, what would it mean to `execute' a text file containing C code? Program, compile thyself! Writing a language processor which is a partial superset of an existing standard is one thing, and quite OK in my book; hacking the kernel to support this automagically is quite another. Perhaps csh should have been made to interpret a strict superset of the Bourne shell, so that normal scripts work under it, and then csh scripts should have been interpreted via "csh script"? Then we wouldn't have this problem. Yes we would. People like to write shells to do their own thing. I don't see this `hack' as a bad thing. It seems to be reasonably general, and I would guess doesn't take much code. The alternative is for the `exec' to fail, and the invoking program build a shell command and resubmit it. In addition, this lets a `script' choose its interpreter. -- Jonathan Clark [NAC,attmail]!mtune!jhc An Englishman never enjoys himself except for some noble purpose. (Root Boy) Jim Cottrell National Bureau of Standards Flamer's Hotline: (301) 975-5688 Th' MIND is the Pizza Palace of th' SOUL