From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Tom Capey Newsgroups: gmane.emacs.help Subject: Re: How to protect a buffer from being deleted by accident? Date: 05 Dec 2002 15:36:19 +0000 Organization: Posted via Supernews, http://www.supernews.com Sender: help-gnu-emacs-admin@gnu.org Message-ID: References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1039103217 21033 80.91.224.249 (5 Dec 2002 15:46:57 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Thu, 5 Dec 2002 15:46:57 +0000 (UTC) Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18JyDH-0005GM-00 for ; Thu, 05 Dec 2002 16:46:55 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18Jy7e-0008Tu-00; Thu, 05 Dec 2002 10:41:06 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!sn-xit-03!sn-xit-01!sn-post-01!supernews.com!corp.supernews.com!not-for-mail Original-Newsgroups: gnu.emacs.help User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 Original-X-Complaints-To: abuse@supernews.com Original-Lines: 34 Original-Xref: shelby.stanford.edu gnu.emacs.help:107766 Original-To: help-gnu-emacs@gnu.org Errors-To: help-gnu-emacs-admin@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.help:4316 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:4316 * Adalbert Perbandt writes: > Hi there, > At my site we're using clearcase mode (clearcase.el) for a long time > with very few problems. Some time ago one of our users deleted the > buffer "*clearcase*" inadvertently. > Now I'd like to provide a simple mechanism which disallows for > deletion of this buffer. I think, it would not be too complex to > implement this but I don't know any simple method to get it > done. Maybe there is a posibility to mark a specific buffer as > "undeletable" or so. (require 'emacs-lock) `toggle-emacs-lock' or within code somewhere (let ((buffer (get-buffer "*clearcase*"))) (when buffer (set-buffer buffer) (setq emacs-lock-from-exiting nil))) something along those lines. /Tom -- "...and so, as the plastic duck of destiny has been sunk by the loofah of fate, and Old Father Time has gone wrinkly in the bath water of eternity, it must be time to pick out the short hairs of hope from the plug hole of infinity." -- Humph