Обсуждение: [PATCH] Set sgml-basic-offset to 1 in .dir-locals.el
[PATCH] Set sgml-basic-offset to 1 in .dir-locals.el
От
ilmari@ilmari.org (Dagfinn Ilmari Mannsåker)
Дата:
This keeps the indentation consistent when editing the documentation
using Emacs.
>From c345671ae4704df500dd17719c5e9973001663c1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Dagfinn=20Ilmari=20Manns=C3=A5ker?= <ilmari@ilmari.org>
Date: Sat, 26 Mar 2016 21:58:32 +0000
Subject: [PATCH] Set sgml-basic-offset to 1 in .dir-locals.el
---
.dir-locals.el | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/.dir-locals.el b/.dir-locals.el
index d8827a6..9574300 100644
--- a/.dir-locals.el
+++ b/.dir-locals.el
@@ -16,4 +16,5 @@
(indent-tabs-mode . t)
(tab-width . 4)))
(sgml-mode . ((fill-column . 78)
- (indent-tabs-mode . nil))))
+ (indent-tabs-mode . nil)
+ (sgml-basic-offset . 1))))
--
2.8.1
--
- Twitter seems more influential [than blogs] in the 'gets reported in
the mainstream press' sense at least. - Matt McLeod
- That'd be because the content of a tweet is easier to condense down
to a mainstream media article. - Calle Dybedahl
On 7/6/16 4:52 AM, Dagfinn Ilmari Mannsåker wrote: > This keeps the indentation consistent when editing the documentation > using Emacs. Unfortunately, sgml-basic-offset is not a "safe" variable, so if we put it into .dir-locals.el, then users will always be bothered with a warning about that. -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Re: [PATCH] Set sgml-basic-offset to 1 in .dir-locals.el
От
ilmari@ilmari.org (Dagfinn Ilmari Mannsåker)
Дата:
Peter Eisentraut <peter.eisentraut@2ndquadrant.com> writes: > On 7/6/16 4:52 AM, Dagfinn Ilmari Mannsåker wrote: >> This keeps the indentation consistent when editing the documentation >> using Emacs. > > Unfortunately, sgml-basic-offset is not a "safe" variable, so if we put > it into .dir-locals.el, then users will always be bothered with a > warning about that. Ah, I see I've added it to safe-local-variables in my .emacs. I must have done that a while back (as evidenced by the date in the patch) and forgotten about it. Oh well, never mind. -- - Twitter seems more influential [than blogs] in the 'gets reported in the mainstream press' sense at least. - Matt McLeod - That'd be because the content of a tweet is easier to condense down to a mainstream media article. - Calle Dybedahl