From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-relay-1.mv.us.adobe.com ([130.248.1.1]) by hawkwind.utcs.toronto.edu with SMTP id <2688>; Tue, 30 Jun 1992 11:29:13 -0400 Received: by mail-relay-1.mv.us.adobe.com; id AA04227; Tue, 30 Jun 92 08:28:55 -0700 Received: from utopia.adobe.com by adobe.com (4.1/SMI-4.1) id AA16036; Tue, 30 Jun 92 08:28:53 PDT Received: by utopia.adobe.com (NeXT-1.0 (From Sendmail 5.52)/NeXT-2.0) id AA11747; Tue, 30 Jun 92 08:29:58 PDT Date: Tue, 30 Jun 1992 11:29:58 -0400 From: haahr@adobe.com Message-Id: <9206301529.AA11747@utopia.adobe.com> To: dylan@ibmpcug.co.uk Subject: Re: -s flag Cc: rc@hawkwind.utcs.toronto.edu > It's a lot better to fix Jove than to 'fix' rc. You could do this like > vi/ex does it. If I execute a subshell command in vi, then any % is > replaced by the current filename, ie > :!mv % %.bak > would be expanded to > :!mv foo foo.bak > etc. This is a lot better than hacking a kludge into rc for the sake of > one editor. i disagree vehemently. shell variable subsitution is a much better defined mechanism than vi's subtituting for %. (e.g., how do you quote %? what if you invoked vi without a filename?) in general, i take issue with any program blindly editing input that the user has typed for another program, even if that other program is a shell. now, one could make the argument that the file should be stored in an environment variable, e.g. $file, and if every editor were coerced to use rc's notion of control-a separated lists, that would even work for multiple files. but $n is a logical place to put the file names, and has no other conventional meaning for subshells invoked from editors. even before Hugh posted his explaination on why jove does what it does, i tended to agree with John that rc should support -s with the same meaning as sh's -s, because it has evolved as a convention among shells, part of the standard options set, like -c and -e. now i'm convinced. paul