[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

distinguishing shells



Cute.  Neither form works from rc, though:

; rc
; ${0+:} echo This is es.
syntax error
; ${0+:} FN={}
syntax error
; $FN echo This is sh.
This is sh.

And only the first form works with es (at least the version I have here):
; es
; ${0+:} echo This is es.
This is es.
; ${0+:} FN={}
syntax error
; $FN echo This is sh.
This is sh.

(BTW, I made a mistake in my comment about my solution yesterday.  It
requires false from rc too, but that doesn't seem too onerous.)

../Dave