From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Andrew M. Scott" Newsgroups: gmane.emacs.devel Subject: Clarification on using safe-local-variable-values Date: Wed, 8 Mar 2006 12:55:59 -0700 Message-ID: <200603081955.k28JtxHO009985@chls308.ch.intel.com> NNTP-Posting-Host: main.gmane.org X-Trace: sea.gmane.org 1141847891 17577 80.91.229.2 (8 Mar 2006 19:58:11 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 8 Mar 2006 19:58:11 +0000 (UTC) Cc: amscott1@sedona.ch.intel.com Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Mar 08 20:58:07 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1FH4lk-00065F-8z for ged-emacs-devel@m.gmane.org; Wed, 08 Mar 2006 20:56:25 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FH4lj-0005jT-LV for ged-emacs-devel@m.gmane.org; Wed, 08 Mar 2006 14:56:23 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FH4lU-0005fr-Ak for emacs-devel@gnu.org; Wed, 08 Mar 2006 14:56:08 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FH4lQ-0005S9-3W for emacs-devel@gnu.org; Wed, 08 Mar 2006 14:56:07 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FH4lP-0005Rk-QV for emacs-devel@gnu.org; Wed, 08 Mar 2006 14:56:03 -0500 Original-Received: from [143.182.124.22] (helo=azsmga101.ch.intel.com) by monty-python.gnu.org with esmtp (Exim 4.52) id 1FH4oJ-0000pN-Pt for emacs-devel@gnu.org; Wed, 08 Mar 2006 14:59:04 -0500 Original-Received: from azsmga001.ch.intel.com ([10.2.17.19]) by azsmga101.ch.intel.com with ESMTP; 08 Mar 2006 11:56:01 -0800 Original-Received: from sedona.ch.intel.com (HELO sedona.intel.com) ([143.182.201.200]) by azsmga001.ch.intel.com with ESMTP; 08 Mar 2006 11:56:02 -0800 X-IronPort-AV: i="4.02,176,1139212800"; d="scan'208"; a="11598749:sNHT23140271" Original-Received: from chls308.ch.intel.com (chls308.ch.intel.com [143.182.232.83]) by sedona.intel.com (8.12.10/8.12.9/d:) with ESMTP id k28Ju0lP016995; Wed, 8 Mar 2006 12:56:00 -0700 (MST) X-Envelope-From: amscott1@sedona.ch.intel.com Original-Received: from chls308.ch.intel.com (localhost [127.0.0.1]) by chls308.ch.intel.com (8.12.10/8.12.8/MailSET/client) with ESMTP id k28Ju02Z009988; Wed, 8 Mar 2006 12:56:00 -0700 Original-Received: (from amscott1@localhost) by chls308.ch.intel.com (8.12.10/8.12.8/MailSET/Submit) id k28JtxHO009985; Wed, 8 Mar 2006 12:55:59 -0700 Original-To: emacs-devel@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:51377 Archived-At: I'm confused at how to use the new safe-local-variable-values added on Feb 14, 2006 is supposed to work. % emacs -Q & C-x C-f ~/.mailrc, where ~/.mailrc is under RCS control which has this at the bottom: # Local Variables: # after-save-hook: build-mail-aliases # End: I get prompted with a *Local Variables* buffer: The local variables list in .mailrc contains variables that are risky (**). Do you want to apply it? You can type y -- to apply the local variables list n -- to ignore the local variables list ! -- to apply the local variables list, and mark these values (*) as safe (in the future, they can be set automatically.)\n\n") ** after-save-hook : build-mail-aliases and with minibuffer: Please type y, n, or !: Q1: Curiously, with my cursor now at the end of the minibuffer line, Emacs did not respond to C-x o or mouse (I wanted to select the contents of the *Local Variables* buffer for submission in this email). Is this intentional? Q2: Exactly where/how is the result of option "!" stored? I chose option "!" and visited the ~/.mailrc file. C-h v safe-local-variable-values still returned nil yet C-h N addition hints that safe-local-variable-values should be updated with my change (somewhere?): At the prompt, the user can choose to save the contents of this local variables list to `safe-local-variable-values'. This new customizable option is a list of variable-value pairs that are known to be safe. Variables can also be marked as safe with the existing `safe-local-variable' property (see `safe-local-variable-p'). However, risky variables will not be added to `safe-local-variable-values' in this way. I also looked and didn't see any update to any ~/.customize* or ~/.emacs.d/* files, or any other file in ~/. If I kill the ~/.mailrc buffer and revisit it, I get prompted with the same *Local Variables* buffer scenario as the first time. Thanks, Andy Scott In GNU Emacs 22.0.50.1 (x86_64-unknown-linux-gnu, X toolkit) of 2006-03-07 on chls308 X server distributor `The XFree86 Project, Inc', version 11.0.40201000 Important settings: value of $LC_ALL: nil value of $LC_COLLATE: C value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: en_US.UTF-8 locale-coding-system: utf-8 default-enable-multibyte-characters: t Major mode: Emacs-Lisp Minor modes in effect: tooltip-mode: t auto-compression-mode: t tool-bar-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t unify-8859-on-encoding-mode: t utf-translate-cjk-mode: t line-number-mode: t Recent input: C-x C-f . m a i l r c C-x o C-x C-c C-g C-h v s a f e - v a e v C-h v s a f e - v a C-x o C-e C-b C-b C-b C-b C-x 1 C-s ! Recent messages: Loading pp...done Type C-x 1 to remove help window. Making completion list... Loading find-func...done Loading jka-compr...done uncompressing files.el.gz...done Mark saved where search started Loading emacsbug... Loading regexp-opt...done Loading emacsbug...done