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

AS doesn't get highlight when using with IMPORT #24

Open
wingyplus opened this issue May 24, 2023 · 3 comments
Open

AS doesn't get highlight when using with IMPORT #24

wingyplus opened this issue May 24, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@wingyplus
Copy link
Collaborator

Consider example below:

Screenshot 2566-05-24 at 14 36 33

The AS keyword doesn't get highlight as a keyword.

@wingyplus wingyplus added the bug Something isn't working label May 24, 2023
@Konubinix
Copy link

For your information, if you use https://github.com/glehmann/earthlyls, it provides several LSP features, including so called semantic tokens, meaning that you can ask the lsp server to provide the highlighting feature (using lsp-semantic-tokens-mode).

At first, I planned to create pull requests in here to improve the highlighting feature, but on second though, a semantically backed highlighting provided by LSP looks more awesome to me.

@wingyplus
Copy link
Collaborator Author

Hi @Konubinix, the PR for the improvement is very welcome. :)

@Konubinix
Copy link

I'm not sure there is anything to do in earthly-emacs to deal with this.

My setup looks like this

(use-package lsp-mode :commands (lsp))

(defun konix/earthfile-mode-hook ()
  (setq indent-tabs-mode nil)
  (setq tab-width 4)
  (setq indent-line-function #'tab-to-tab-stop)
  (setq-local lsp-semantic-tokens-enable t)
  (lsp)
  )

(add-hook #'earthfile-mode-hook
          #'konix/earthfile-mode-hook)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants