From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5599 invoked by alias); 14 Nov 2014 13:31:36 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 19385 Received: (qmail 12429 invoked from network); 14 Nov 2014 13:31:33 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham version=3.3.2 Message-ID: <546601E9.3040200@necoro.eu> Date: Fri, 14 Nov 2014 14:21:45 +0100 From: =?windows-1252?Q?Ren=E9_Neumann?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 MIME-Version: 1.0 To: zsh-users@zsh.org Subject: Re: passing a zsh option when opening an xterm References: <20141114122739.GA24113@apartia.fr> In-Reply-To: <20141114122739.GA24113@apartia.fr> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit Am 14.11.2014 um 13:27 schrieb Louis-David Mitterrand: > Hi, > > When opening my fixed xterm's from my desktop startup file I'd like them > to not quit when accidentaly pressing CTRL-D. > > How can I pass zsh's ignoreeof to the xterm? > > (I don't want that option in my .zshrc as I like to terminate temporary > xterm's with CTRL-D) > > I tried "xterm -e zsh -i -7" which works but wondering if there is > another way? What speaks against using the line above in your desktop startup file? Especially as you require to have behavior A for 'startup xterms' and behavior B for 'temporary xterms' -- how is the shell expected to distinguish the one from the other¹? - René ¹ Of course you could create a symlink 'startup-xterm' linking to xterm, and then differentiate in .zshrc between xterm and startup-xterm. But when allowing such overhead, you could equally well create a wrapper script or something alike.