smalisp
A very simple language server for smali with definition support & auto-completion.
| Code completion |
Docs |
 |
 |
Installation
pip
pip install -U smalisp
From source
pip install -U git+https://github.com/AbhiTheModder/smalisp.git
Extensions & Setup
Zed Extension (Local Development)
Prerequisites: Zed editor installed.
- Extension path:
extensions/zed.
- Open the Extensions page in Zed.
- Click the Install Dev Extension button (or run the
zed: Install Dev Extension command).
- Select the directory containing your Zed extension (the folder that contains the manifest and source).
Reference: https://zed.dev/docs/extensions/developing-extensions#developing-an-extension-locally
Note: These dev extensions are not yet officially accepted in the Zed extension registry; acceptance is expected soon.
VSCode Extension (Local Development)
Prerequisites: VSCode installed.
- Extension path:
extensions/vscode.
- Build or obtain the VSIX package for the extension from the releases page of this repository.
- In VSCode, go to Extensions view, click the three-dot menu, choose Install from VSIX..., and select the downloaded
.vsix file.
- Alternatively, run
code --install-extension path/to/extension.vsix from the terminal.
Note: The VSCode extension is not yet published in the official VSCode Marketplace; use local VSIX for testing.
Helix
- Prerequisites: Helix installed.
Install/ensure smalisp is installed in your Python environment (e.g. pip install -U smalisp). Then edit ~/.config/helix/languages.toml and add the following:
[language-server.smalisp]
command = "smalisp" # Or path to smalisp binary
[[language]]
name = "smali"
language-servers = [ "smalisp" ]
- Official integration PR for Helix has been submitted; Smalisp should be available out-of-the-box soon.
Vim/NeoVim
- Associate smali filetype with file extensions:
autocmd BufNewFile,BufRead *.smali setlocal filetype=smali
- In order to install syntax highlighting declare it with your plugin manager (for example vim-plug):
Plug 'Snape3058/vim-smali'
Plug 'neoclide/coc.nvim', {'branch': 'release'}
{
"languageserver": {
"smalisp": {
"command": "smalisp",
"filetypes": ["smali"]
}
}
}
Plug 'prabirshrestha/vim-lsp'
autocmd User lsp_setup call lsp#register_server({
\ 'name': 'smalisp',
\ 'cmd': {server_info->['smalisp']},
\ 'whitelist': ['smali'],
})
Emacs (lsp-mode)
- Prerequisites: Emacs with lsp-mode and eglot options.
- Setup: enable lsp for
smali-mode and configure the server to run smalisp.
- See lsp-mode docs for exact config syntax.