Skip to content

Commit

Permalink
chore(emacs): fix cask warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
gebner authored and leodemoura committed Oct 21, 2016
1 parent 8c47923 commit 175e4ec
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 9 deletions.
1 change: 1 addition & 0 deletions .gitignore
@@ -1 +1,2 @@
.cask
*.elc
1 change: 1 addition & 0 deletions Cask
Expand Up @@ -3,6 +3,7 @@
(package-file "lean-mode.el")
(development
(depends-on "cl-lib")
(depends-on "company")
(depends-on "dash" 2.8.0)
(depends-on "dash-functional" "1.1.0")
(depends-on "ert-runner")
Expand Down
8 changes: 4 additions & 4 deletions lean-debug.el
Expand Up @@ -10,23 +10,23 @@
(defun lean-turn-on-debug-mode (&optional print-msg)
(interactive)
(when (eq major-mode 'lean-mode)
(when (or (called-interactively-p) print-msg)
(when (or (called-interactively-p 'any) print-msg)
(message "lean: turn on debug mode"))
(get-buffer-create lean-debug-buffer-name)
(setq-local lean-debug-mode t)))

(defun lean-turn-off-debug-mode (&optional print-msg)
(interactive)
(when (eq major-mode 'lean-mode)
(when (or (called-interactively-p) print-msg)
(when (or (called-interactively-p 'any) print-msg)
(message "lean: turn off debug mode"))
(setq-local lean-debug-mode nil)))

(defun lean-toggle-debug-mode ()
(interactive)
(if lean-debug-mode
(lean-turn-off-debug-mode (called-interactively-p))
(lean-turn-on-debug-mode (called-interactively-p))))
(lean-turn-off-debug-mode (called-interactively-p 'any))
(lean-turn-on-debug-mode (called-interactively-p 'any))))

(defun lean-output-to-buffer (buffer-name format-string args)
(with-current-buffer
Expand Down
6 changes: 3 additions & 3 deletions lean-flycheck.el
Expand Up @@ -5,7 +5,7 @@
;;
;; Author: Soonho Kong
;;

(require 'flycheck)
(require 'lean-settings)
(require 'lean-server)

Expand Down Expand Up @@ -50,15 +50,15 @@
(defun lean-flycheck-turn-on ()
(interactive)
(unless lean-flycheck-use
(when (interactive-p)
(when (called-interactively-p 'any)
(message "use flycheck in lean-mode"))
(setq lean-flycheck-use t))
(flycheck-mode t))

(defun lean-flycheck-turn-off ()
(interactive)
(when lean-flycheck-use
(when (interactive-p)
(when (called-interactively-p 'any)
(message "no flycheck in lean-mode")))
(flycheck-mode 0)
(setq lean-flycheck-use nil))
Expand Down
4 changes: 2 additions & 2 deletions lean-mode.el
Expand Up @@ -39,7 +39,7 @@
(defun lean-execute (&optional arg)
"Execute Lean in the current buffer"
(interactive)
(when (called-interactively-p)
(when (called-interactively-p 'any)
(setq arg (read-string "arg: " arg)))
(let ((target-file-name
(or
Expand Down Expand Up @@ -78,7 +78,7 @@
(if (looking-at "->") t nil))))))

(defun lean-tab-indent ()
(cond ((looking-back (rx line-start (* white)))
(cond ((looking-back (rx line-start (* white)) nil)
(eri-indent))
(t (indent-for-tab-command))))

Expand Down

0 comments on commit 175e4ec

Please sign in to comment.