Fix void-symbol errors in compilation buffers

Occurs when :lang ruby is enabled, because the rspec-mode package
autoloads an advice, but not the advice function. Still, it seems silly
to do this advice before the package is loaded, so we disable it.
This commit is contained in:
Henrik Lissner 2018-06-11 14:21:35 +02:00
parent a25eff0189
commit f70c9ebb71
No known key found for this signature in database
GPG Key ID: 5F6C0EA160557395

View File

@ -83,6 +83,13 @@ environment variables."
(("class" "def" "while" "do" "module" "for" "until") () "end") (("class" "def" "while" "do" "module" "for" "until") () "end")
;; Rake ;; Rake
(("task" "namespace") () "end"))) (("task" "namespace") () "end")))
;; This package autoloads this advice, but does not autoload the advice
;; function, causing void-symbol errors when using the compilation buffer
;; (even for things unrelated to ruby/rspec). Even if the function were
;; autoloaded, it seems silly to add this advice before rspec-mode is loaded,
;; so remove it anyway!
(advice-remove 'compilation-buffer-name 'rspec-compilation-buffer-name-wrapper)
:config :config
(remove-hook 'ruby-mode-hook #'rspec-enable-appropriate-mode) (remove-hook 'ruby-mode-hook #'rspec-enable-appropriate-mode)
(map! :map (rspec-mode-map rspec-verifiable-mode-map) (map! :map (rspec-mode-map rspec-verifiable-mode-map)