From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.help Subject: RE: (kill-buffer "*scratch*") Date: Thu, 23 Sep 2004 13:45:08 -0700 Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: References: <81hdporegw.fsf@adboyd.com> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1095972390 32225 80.91.229.6 (23 Sep 2004 20:46:30 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 23 Sep 2004 20:46:30 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Sep 23 22:46:14 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1CAaTl-0001op-00 for ; Thu, 23 Sep 2004 22:46:13 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CAaZn-000298-G9 for geh-help-gnu-emacs@m.gmane.org; Thu, 23 Sep 2004 16:52:27 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CAaZX-000258-8a for help-gnu-emacs@gnu.org; Thu, 23 Sep 2004 16:52:12 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CAaZT-00023f-2l for help-gnu-emacs@gnu.org; Thu, 23 Sep 2004 16:52:09 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CAaZS-00023b-BS for help-gnu-emacs@gnu.org; Thu, 23 Sep 2004 16:52:06 -0400 Original-Received: from [141.146.126.228] (helo=agminet01.oracle.com) by monty-python.gnu.org with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.34) id 1CAaT0-0000am-8X for help-gnu-emacs@gnu.org; Thu, 23 Sep 2004 16:45:26 -0400 Original-Received: from rgmgw1.us.oracle.com (rgmgw1.us.oracle.com [138.1.191.10]) by agminet01.oracle.com (Switch-3.1.4/Switch-3.1.0) with ESMTP id i8NKjHV9027885; Thu, 23 Sep 2004 13:45:19 -0700 Original-Received: from rgmgw1.us.oracle.com (localhost [127.0.0.1]) by rgmgw1.us.oracle.com (Switch-3.1.4/Switch-3.1.0) with ESMTP id i8NKjGkd011986; Thu, 23 Sep 2004 14:45:16 -0600 Original-Received: from dradamslap (dradams-lap.us.oracle.com [130.35.177.126]) by rgmgw1.us.oracle.com (Switch-3.1.4/Switch-3.1.0) with SMTP id i8NKj9gx011650; Thu, 23 Sep 2004 14:45:16 -0600 Original-To: "J. David Boyd" , X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) In-Reply-To: <81hdporegw.fsf@adboyd.com> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:20840 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:20840 Just to make sure you also know these alternatives: - Instead of using buffer *scratch*, you can always use a different buffer in Emacs Lisp mode. Find-file foo.el, for instance. - You can `write-file' buffer *scratch* into a file, to save its contents. Buffer *scratch* is just a buffer in Emacs Lisp mode, more or less. Kevin Rodgers writes: > > I think I wrote it in the scratch buffer and closed emacs without > > saving it. > > Of course, emacs didn't asked me if I would like to save it. > > But it did tell you: > > ;; This buffer is for notes you don't want to save, and for Lisp evaluation. > ;; If you want to create a file, visit that file with C-x C-f, > ;; then enter the text in that file's own buffer. > > Try adding this to your .emacs file: > > (save-excursion > (set-buffer "*scratch*") > (setq buffer-offer-save t)) Excellent idea. I'm adding this to my .emacs right away, and thanks.