Path: utzoo!utgpu!water!watmath!clyde!rutgers!sdcsvax!ucsdhub!jack!sdeggo!dave From: dave@sdeggo.UUCP (David L. Smith) Newsgroups: comp.unix.wizards Subject: Csh/sh bug or feature? Message-ID: <170@sdeggo.UUCP> Date: 12 Jan 88 07:56:33 GMT Organization: Lazy Programmer's Society of San Diego Lines: 41 I was playing around with csh the other day and noticed something rather interesting. In the string returned by a program called through the backquotes quotes are ignored, and filename expansion is attempted when the variable is set unless noglob is set. This also happens in sh (except, of course, that noglob doesn't exsist in sh). For example (with csh), if foo contained: 'this is * ' (with the quotes and everything) and I do: set foo=`cat foo` echo $foo returns: 'this is (and here is the contents of the directory I was in when I did the set) if I then set noglob, and echo foo again, I get the same thing. However, if I had done instead set foo='this is *' echo $foo gives: 'this is (and the contents of my _current_ directory) set noglob and echo $foo returns: 'this is *' The question is, is there any reason for them to be treated differently? It seems as if it would be beneficial for the output to be directly substituted for the `` string and be subject to the same rules as if it had been in the file all along. -- David L. Smith {sdcsvax!jack,ihnp4!jack, hp-sdd!crash, pyramid}!sdeggo!dave sdeggo!dave@amos.ling.edu Sinners can repent, but stupid is forever.