Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: Update so it works with LSP's API and allow for custom path to the scry binary #2

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 14 additions & 4 deletions lsp-crystal.el
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
;; URL: https://github.com/brantou/lsp-crystal.el
;; Keywords: languages crystal
;; Version: 0.1.0
;; Package-Requires: ((crystal-mode "0.1.0") (lsp-mode "4.0"))
;; Package-Requires: ((crystal-mode "0.2.0") (lsp-mode "6.1"))

;; This file is not part of GNU Emacs.

Expand Down Expand Up @@ -43,9 +43,19 @@
(require 'lsp-mode)
(require 'crystal-mode)

(lsp-define-stdio-client lsp-crystal "crystal"
#'crystal-find-project-root
'("scry"))

(defcustom lsp-server-crystal-scry "scry"
"Path to the scry binary"
:type 'string
:group 'lsp-crystal)


(lsp-register-client
(make-lsp-client :new-connection
(lsp-stdio-connection lsp-server-crystal-scry)
:major-modes '(crystal-mode)
:priority 0
:server-id 'scry))

(provide 'lsp-crystal)
;;; lsp-crystal.el ends here