Skip to contentSkip to conversation

Documentation: fix emacs indenting howto filename expansion

PATCH New Randy Dunlap 1 participant 1 message Jan 30, 2009 Documentation

lore
Share & tools
lore
#0 lore raw

PATCH 3/4 Documentation: fix emacs indenting howto filename expansion

From: Dan Carpenter <[email protected]>
Subject: fix emacs indenting howto filename expansion

I don't think emacs understands tilde expansion, so use "expand-file-name" to do that.

---

---
 Documentation/CodingStyle |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
Documentation/CodingStyle +2 -1
@@ -498,7 +498,8 @@ values.  To do the latter, you can stick
             (let ((filename (buffer-file-name)))
               ;; Enable kernel mode for the appropriate files
               (when (and filename
-                         (string-match "~/src/linux-trees" filename))
+                         (string-match (expand-file-name "~/src/linux-trees")
+                                       filename))
                 (setq indent-tabs-mode t)
                 (c-set-style "linux-tabs-only")))))