aboutsummaryrefslogtreecommitdiffstats
path: root/oni-java.el
diff options
context:
space:
mode:
Diffstat (limited to 'oni-java.el')
-rw-r--r--oni-java.el10
1 files changed, 8 insertions, 2 deletions
diff --git a/oni-java.el b/oni-java.el
index 73a254a..eaf6e20 100644
--- a/oni-java.el
+++ b/oni-java.el
@@ -4,8 +4,8 @@
;; Author: Tom Willemse <tom@ryuslash.org>
;; Keywords: local
-;; Version: 20190611081136
-;; Package-Requires: (oni-fci oni-data-dir lsp-java company-lsp lsp-ui)
+;; Version: 20190623093216
+;; Package-Requires: (oni-fci oni-data-dir lsp-java company-lsp lsp-ui hydra)
;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
@@ -26,6 +26,7 @@
;;; Code:
+(require 'hydra)
(require 'lsp-java)
(require 'oni-data-dir)
@@ -37,6 +38,9 @@
"Set `comment-auto-fill-only-comments' to true locally."
(setq-local comment-auto-fill-only-comments t))
+(defhydra java-refactor-hydra (:color blue)
+ ("r" lsp-rename "Rename object"))
+
(setq lsp-java-server-install-dir
(oni-data-dir-locate "lsp-java/server/"))
@@ -56,6 +60,8 @@
(add-to-list 'company-backends 'company-lsp)
+(define-key java-mode-map (kbd "C-c r") 'java-refactor-hydra/body)
+
;;;###autoload(with-eval-after-load 'cc-mode (require 'oni-java))
(provide 'oni-java)