X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-1.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,UNPARSEABLE_RELAY X-Spam-Check-By: sourceware.org X-Yahoo-SMTP: jenXL62swBAWhMTL3wnej93oaS0ClBQOAKs8jbEbx_o- Date: Tue, 10 May 2011 18:16:54 -0400 From: Christopher Faylor To: cygwin AT cygwin DOT com Subject: Re: Who's using "CYGWIN=tty" and why? Message-ID: <20110510221654.GA15744@ednor.casa.cgf.cx> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <20110509161028 DOT GJ27739 AT calimero DOT vinschen DOT de> <0105D5C1E0353146B1B222348B0411A209E8030CB9 AT NIHMLBX02 DOT nih DOT gov> <20110510171846 DOT GA27537 AT ednor DOT casa DOT cgf DOT cx> <0105D5C1E0353146B1B222348B0411A209E8030CCE AT NIHMLBX02 DOT nih DOT gov> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <0105D5C1E0353146B1B222348B0411A209E8030CCE@NIHMLBX02.nih.gov> User-Agent: Mutt/1.5.20 (2009-06-14) Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com On Tue, May 10, 2011 at 06:11:35PM -0400, Buchbinder, Barry (NIH/NIAID) [E] wrote: >Christopher Faylor sent the following at Tuesday, May 10, 2011 1:19 PM >>If we changed the /dev/console to /dev/consN (where N is a unique number >>for each console window) would that address your use case? > >Yes, it works for me if there would be a reasonably small (preferably >single digit) number in the output of tty or ps. Yep. That is the plan. >>You would not be able to do something like echo foo >/dev/cons4 and have >>foo be echoed another console window though. > >Since I haven't been on a real Unix/POSIX machine since the late '80s, >I'd forgotten about that. Now you made me want to DO it! :-) Heh. I knew I shouldn't have mentioned it. This was actually one of the first things that impressed me about Cygwin when I first started using it. Of course, when I first started it only worked about half the time, but still... The way I'm implementing this you should be able if /dev/consN is actually associated with a console but you won't be able to do anything other than verify existence. >>Eliminating the special case of tty handling >>would simplify the cygwin pty layer, shrink the size of the DLL, and >>generally make Cygwin a little easier to maintain. > >Even if you don't accommodate me, that's OK, if your lives will be >easier. As I wrote, if I find that I really miss tty identification, >I can learn to use mintty. (Or maybe I should just switch - but not >today.) I actually have the /dev/cons about 3/4 finished. If we do decide to get rid of CYGWIN=tty then /dev/cons may become /dev/tty again and ptys will become /dev/pty. cgf -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple