Skip to content

A set of plugins and configuration files that aims to turn Lite XL into a proper IDE.

Notifications You must be signed in to change notification settings

PerilousBooklet/lite-xl-ide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

66 Commits
 
 
 
 
 
 

Repository files navigation

Lite XL IDE setup

Introduction

Documentation for a set of plugins and configuration files that aims to turn Lite XL into a proper IDE.

(This project is still WIP.)

This repository no longer contains an install script to setup Lite XL IDE.

Instead, I am working on adding IDE bundle metapackages to Adam's repo.

This way, if I wanted to install and IDE setup for Java or Python, I could just run one simple command in the terminal, like lpm install ide_java or lpm install ide_python.

With such a command, lpm (Lite XL's own package manager') would take care of installing executable files for LSP servers, linters, formatters and IDE-related plugins.

One thing to keep in mind though, is that, at the moment, the ideal distribution to use a Lite XL IDE manual setup on is Arch Linux (or a derivative), because all the lsp servers, linters and formatters have a correspondent arch package, either in the official repo or in the AUR.

Table of Contents

  1. Installation
  2. Features
  3. Language Support Status
  4. LSP Bundle Support Status
  5. Credits

Installation

Install colors and languages

lpm install meta_colors meta_languages

Install my custom devicons plugin

lpm add https://github.com/PerilousBooklet/lite-xl-devicons.git
lpm install devicons

Install the basic IDE plugins

lpm install ide

or a language-specific ide metapackage: e.g. lpm install ide_c for C/C++ development.

Install some more plugins

lpm install "exec" markers extend_selection_line sort titleize

Install an LSP server

Manual way

Add the following code to USERDIR/init.lua (e.g. lspconfig.clangd.setup() enables the clangd LSP server for C/C++):

local lsp = require "plugins.lsp"
lspconfig.clangd.setup()

Do the same by adding an appropriate lspconfig.lsp_name.setup() instruction for every desired language.

The LSP servers names can be found in here.

Automated way

Install an lsp bundle from here (e.g. lpm install lsp_c for C/C++ development).

Some other IDE setup steps

Enable automatic linting upon opening and saving a file by adding the following code inside of USERDIR/init.lua:

local lintplus = require \"plugins.lintplus\"
lintplus.setup.lint_on_doc_load()  -- enable automatic linting upon opening a file
lintplus.setup.lint_on_doc_save()  -- enable automatic linting upon saving a file

Add code snippets by downloading the JSON files from this repo's snippets folder into a USERDIR/plugins/snippets/json folder and then writing the following code inside of USERDIR/init.lua:

local lsp_snippets = require \"plugins.lsp_snippets\"
lsp_snippets.add_paths {'plugins/snippets/json'}

Allow format-on-save by adding the following code to the init.lua:

config.format_on_save = true

Features

  • Syntax highlighting for 100+ languages
  • Intellisense support for 40+ languages
  • Custom project treeview devicons
  • VSCode-like minimap
  • Project-wide text string search
  • Project-wide filename search
  • Multi-cursor editing
  • Single/multi-line commenting with shortcuts
  • Go to line n command
  • Todo tree view
  • Code block definition preview on hover (like for TailwindCSS in VSCode)
  • Integrated terminal
  • Git integration
  • Builder integration
  • Debugger integration
  • Markdown support via ghmarkdown or mdpreview

WIP

  • Foldable code blocks
  • Horizontal scrolling for project treeview
  • Automatic textEdit for in-file dependency reference
  • Ligatures support
  • Github Copilot integration
  • Custom Canvas API to allow an external renderer to draw on a surface that Lite XL will render on screen
  • Markdown renderer integration (mdpreview plugin + canvas module)

TODO

  • Document symbols treeview
  • Support goto-definition/implementation for decompiled libraries (es. java, minecraft mods)
  • Simultaneous tag rename
  • Project-wide refactoring
  • Project template manager
  • Tmux integration
  • Docker integration

Language support status

Language Syntax High. LSP support Linting Snippets Formatter Builder Debugger
Arduino
Bash ex
C#
C/C++
Clojure
Crystal *
CSS
D
Dart
Elixir
Elm
Erlang *
F#
Fortran
GDScript
Go
Groovy *
Haskell
HTML
Java
Javascript
JSON
Julia *
Kotlin
Lua ex
Nim * *
Nix
Ocaml
Odin
OpenSCAD
Perl
PHP ex
Python
R
Ruby
Rust
Scala
SQL
Svelte
Tailwind *
TeX
TOML
Typescript
Typst *
V
Vala *
XML
Zig ex
YAML

*: there are still some problems to solve

ex: external linter

LSP Bundle support status

Language LSP Bundle LSP Bundle Package IDE Package
Arduino
Bash
C#
C/C++ lsp_c ide_c
Clojure
Crystal
CSS
Dart
Elixir
ELM
Erlang
Go
Groovy
Haskell
HTML
Java lsp_java ide_java
Javascript lsp_typescript ide_javascript
JSON lsp_json
Julia
Kotlin
Lisp
Lua lsp_lua ide_lua
Nim
Nix
Ocaml
Odin
OpenSCAD
Perl
PHP
Python lsp_python ide_python
R
Ruby
Rust lsp_rust ide_rust
Scala
SQL
Svelte
Tailwind
TeX lsp_tex ide_tex
Typescript lsp_typescript
Typst
XML
YAML lsp_yaml
Zig lsp_zig ide_zig

Credits

About

A set of plugins and configuration files that aims to turn Lite XL into a proper IDE.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages