X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=-0.9 required=5.0	tests=AWL,BAYES_40,SPF_HELO_PASS,T_RP_MATCHES_RCVD
X-Spam-Check-By: sourceware.org
Mail-Followup-To: cygwin@cygwin.com
To: cygwin@cygwin.com
From: Gary <cygwin@garydjones.name>
Subject: Re: getting 'clear' to work in Emacs shell
Date: Tue, 19 Oct 2010 09:45:45 +0200
Lines: 56
Message-ID: <i9jiba$nm6$1@dough.gmane.org>
References: <287016.30328.qm@web56705.mail.re3.yahoo.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (cygwin)
X-No-Archive: Yes
Mail-Copies-To: never
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

Jeff Rancier wrote:
> The 'clear' work's  in a Cygwin Bash session,
>
> C106426@USLINY2R86KRP8 ~
> $ alias  clear
> alias clear='cat ~/.cls'

Umm... why have you done this?
,----
| $ man clear
| 
| clear(1)                                                              clear(1)
| 
| NAME
|        clear - clear the terminal screen
| ...
`----

> within Emacs:
>
> C-z runs the command  shell
>    which is an interactive compiled Lisp function in `shell'.
> (shell  &optional BUFFER)

Odd. I see
,----
| C-z runs the command suspend-frame, which is an interactive compiled
| Lisp function in `frame.el'.
`----
Perhaps you have customised this?

> All I get within an Emacs shell session is the following, without
> clearing the
> screen.  Is there  some envionment variable I need to set here?

,----
| M-x eshell
`----

:-)

Alternatively you might like to read http://www.khngai.com/emacs/cygwin.php -
"When the "clear" command is entered into the bash shell, it is expected
to clear the entire shell buffer. However, this does not work for bash
shell under Gnu Emacs. The following lisp statements solve the problem."

(Note: I haven't actually tried the indicated elisp, but my point is
that this does not really seem to be a Cygwin problem, rather an emacs
one... if it is really a problem at all. If the suggeted solution
doesn't work there are more emacs specific lists where you would
probably be better off asking.)

-- 
Gary        Please do NOT send me 'courtesy' replies off-list.
GNU Emacs 23.2.1
emacsclient 23.2


--
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

