GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - EmmyLua/EmmyLua-LanguageServer

BranchesTags
Open more actions menu

Latest commit

 

History

375 Commits
375 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
EmmyLua-Common
EmmyLua-Common
 
 
EmmyLua-LS
EmmyLua-LS
 
 
IntelliJ-Core
IntelliJ-Core
 
 
gradle/wrapper
gradle/wrapper
 
 
img
img
 
 
.gitignore
.gitignore
 
 
build.gradle
build.gradle
 
 
gradlew
gradlew
 
 
gradlew.bat
gradlew.bat
 
 
readme.md
readme.md
 
 
settings.gradle
settings.gradle
 
 

Repository files navigation

Emmy Lua Language Server

Use EmmyLuaAnalyzer Please

CI status Download
Build status EmmyLua-LS-all.jar

Emmy lua Language server have lots of features for lua language, including:

  • Find usages
  • Go to definition
  • Comment based type/class annotation
  • Basic completion

For an exhaustive list of features see the intellij plugin description.

Requirements

  • install JDK

Building

Run from root:

$ gradlew shadowJar

The EmmyLua-LS-all.jar file will be created in EmmyLua-LanguageServer/EmmyLua-LS/build .

Running Server

To run the language server use:

$ java -cp EmmyLua-LS-all.jar com.tang.vscode.MainKt

Adding to an Sublime

Just pass the instantiating instruction to the LSP plugin.

Example: adding EmmyLua to SublimeText with Sublime-LSP:

  • install the LSP plugin in sublime
  • add emmy as a client to LSP.sublime-settings:
{
    "clients":
    {
        "emmy":
        {
            "command":
            [
                "java",
                "-cp",
                "<path to jar>/*",
                "com.tang.vscode.MainKt"
            ],
            "enabled": true,
            "languageId": "lua",
            "scopes":
            [
                "source.lua"
            ],
            "syntaxes":
            [
                "Packages/Lua/Lua.sublime-syntax"
            ]
        }
    }
}

Adding to Emacs

you can use lsp-lua-emmy as lsp client.

add following code to your ~/.emacs or .emacs.d/init.el .

(use-package lsp-mode
  :ensure t
  :commands lsp
  :hook ((lua-mode) . lsp)
  :config
  )

(use-package company-lsp
  :ensure t
  :after lsp-mode
  :config
  (setq company-lsp-enable-recompletion t)
  (setq lsp-auto-configure nil)         ;该功能会自动执行(push company-lsp company-backends)
  )

(use-package lsp-lua-emmy
  :demand
  :ensure nil
  :load-path "~/github/lsp-lua-emmy"
  :hook (lua-mode . lsp)
  :config
  (setq lsp-lua-emmy-jar-path (expand-file-name "EmmyLua-LS-all.jar" user-emacs-directory))
  )

(defun set-company-backends-for-lua()
  "Set lua company backend."
  (setq-local company-backends '(
                                 (
                                  company-lsp
                                  company-lua
                                  company-keywords
                                  company-gtags
                                  company-yasnippet
                                  )
                                 company-capf
                                 company-dabbrev-code
                                 company-files
                                 )))

(use-package lua-mode
  :ensure t
  :mode "\\.lua$"
  :interpreter "lua"
  :hook (lua-mode . set-company-backends-for-lua)
  :config
  (setq lua-indent-level 4)
  (setq lua-indent-string-contents t)
  (setq lua-prefix-key nil)
  )

work with company-mode and lua-mode in Emacs 26.1:

work-with-emacs

Adding to Vim/NeoVim

Install Vim-EasyComplete. Run InstallLspServer after opening a lua file with vim.

About

No description, website, or topics provided.

Resources

Readme
Activity
Custom properties

Stars

161 stars

Watchers

6 watching

Forks

27 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.