summaryrefslogtreecommitdiff
path: root/elisp
diff options
context:
space:
mode:
Diffstat (limited to 'elisp')
-rw-r--r--elisp/pylint-flymake.el11
1 files changed, 11 insertions, 0 deletions
diff --git a/elisp/pylint-flymake.el b/elisp/pylint-flymake.el
new file mode 100644
index 0000000..835409e
--- /dev/null
+++ b/elisp/pylint-flymake.el
@@ -0,0 +1,11 @@
+(when (load "flymake" t)
+ (defun flymake-pylint-init ()
+ (let* ((temp-file (flymake-init-create-temp-buffer-copy
+ 'flymake-create-temp-inplace))
+ (local-file (file-relative-name
+ temp-file
+ (file-name-directory buffer-file-name))))
+ (list "epylint" (list local-file))))
+
+ (add-to-list 'flymake-allowed-file-name-masks
+ '("\\.py\\'" flymake-pylint-init)))