figleaf.el: add code to auto-enable the annotation mode for all source files
authorBrian Warner <warner@allmydata.com>
Thu, 18 Jan 2007 08:00:11 +0000 (01:00 -0700)
committerBrian Warner <warner@allmydata.com>
Thu, 18 Jan 2007 08:00:11 +0000 (01:00 -0700)
misc/figleaf.el

index 6a4323b84885b680bb33f5f76671f1a1b299f296..fef42e089db85c21e024a66bdfab1a0fd51bc531 100644 (file)
   () ; forms run on mode entry/exit
 )
 
+(defun maybe-enable-figleaf-mode ()
+  (if (string-match "/src/allmydata/" (buffer-file-name))
+      (figleaf-annotation-minor-mode t)
+    ))
+
+(add-hook 'python-mode-hook 'maybe-enable-figleaf-mode)