From af089b245a9b18bc6cd005260dcf4cd60fe51cd7 Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Thu, 23 Oct 2014 02:39:08 -0700 Subject: [PATCH] add flycheck remove flymake. comment dwim is back to C-M-; add themes and js dependencies. --- init.el | 30 +++++------------------------- 1 file changed, 5 insertions(+), 25 deletions(-) diff --git a/init.el b/init.el index d29f0c77..451e7442 100644 --- a/init.el +++ b/init.el @@ -49,7 +49,8 @@ gitconfig-mode starter-kit-ruby mo-git-blame auto-complete project-root popup web-beautify js2-mode js3-mode sphinx-doc ansi-color pytest - exec-path-from-shell base16-theme) + exec-path-from-shell base16-theme slime + swank-js) "Packages that must be installed at launch.") (defun ensure-package-installed (packages) @@ -154,6 +155,8 @@ Return a list of installed packages or nil for every package not installed." (setq custom-file "~/.emacs.d/custom.el") (when (file-exists-p custom-file) (load custom-file)) +(add-hook 'after-init-hook #'global-flycheck-mode) + ;; ============================================================================= ;; Misc ;; ============================================================================= @@ -200,29 +203,6 @@ Return a list of installed packages or nil for every package not installed." (shell-command (concat "echo " (shell-quote-argument (ffip-get-buffer-name)) " | tmux loadb -"))) -;; ============================================================================= -;; Flymake -;; ============================================================================= - -(require 'flymake) -(require 'flymake-cursor) - -(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 "pyflakes" (list local-file)))) - -(add-to-list 'flymake-allowed-file-name-masks '("\\.py\\'" flymake-pylint-init)) - -;; Load flymake on non-temp buffers -(add-hook 'python-mode-hook - (lambda () (unless (or (eq buffer-file-name nil) - (eq (file-name-directory buffer-file-name) nil)) - (flymake-mode 1)))) - ;; ============================================================================= ;; Python ;; ============================================================================= @@ -309,7 +289,7 @@ Return a list of installed packages or nil for every package not installed." (global-set-key (kbd "C-x w") 'whitespace-mode) (global-set-key (kbd "C-x C-r") (lambda () (interactive) (revert-buffer t t))) (global-set-key (kbd "M-g") 'goto-line) -(global-set-key (kbd "C-c C-c") 'comment-dwim) +(global-set-key (kbd "C-M-;") 'comment-dwim) (global-set-key (kbd "C-c t") 'pytest-one) (global-set-key (kbd "C-c e") 'os-copy) (global-set-key (kbd "C-x O") (lambda () (interactive) (other-window -1)))