Commitd44ecfb7Recorded24 Apr 2026Repositorysigil-lsp

Extract sigil-lsp from sigil monorepo

Message

Initial standalone release of sigil-lsp (Language Server Protocol implementation for Sigil), extracted from the sigil monorepo at d39c7f8c using git filter-repo.

Scaffolding added: - README.md module map, usage, build/test commands - .gitignore build/, .sigil/ - manifest.scm minimal Scheme dev env (gcc-toolchain, make, pkg-config) - dev-redirects.sgl map from-git deps back to local sibling checkouts

package.sgl: - version 0.13.1, url codeberg.org/sigil/sigil-lsp - 5 from-workspace deps (stdlib, ansi, args, format, docs) swapped to from-git monorepo-resident form, pinned ^0.13.1 - sigil-json ^0.13.1 (already external), sigil-log ^0.13.0 (no v0.13.1 tag)

Follows procedures/sigil-package-extraction playbook.

Changed
 .gitignore        |  2 ++
 README.md         | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 dev-redirects.sgl | 13 +++++++++++++
 manifest.scm      |  7 +++++++
 package.sgl       | 13 +++++++------
 sigil.lock        | 38 ++++++++++++++++++++++++++++++++++++++
 6 files changed, 128 insertions(+), 6 deletions(-)
Diff
.gitignoreadded
@@ -0,0 +1,2 @@
+1
build/
+2
.sigil/
README.mdadded
@@ -0,0 +1,61 @@
+1
# sigil-lsp
+2
+3
Language Server Protocol implementation for
+4
[Sigil](https://codeberg.org/sigil/sigil). Provides diagnostics, hover,
+5
completion, go-to-definition, formatting, and code actions for Sigil
+6
source files, exposed over LSP 3.17 / JSON-RPC 2.0 on stdio.
+7
+8
Invoked by editors through `sigil lsp serve` (registered as a
+9
subcommand of sigil-cli).
+10
+11
## Modules
+12
+13
| Module | Purpose |
+14
|-------------------------------|-------------------------------------------------|
+15
| `(sigil lsp)` | Top-level `lsp-serve` entry point |
+16
| `(sigil lsp server)` | Server loop and method dispatch |
+17
| `(sigil lsp protocol)` | JSON-RPC 2.0 framing and message shapes |
+18
| `(sigil lsp documents)` | In-memory document cache keyed by URI |
+19
| `(sigil lsp positions)` | 0-based line/character helpers |
+20
| `(sigil lsp diagnostics)` | Parse errors + lint warnings as LSP diagnostics |
+21
| `(sigil lsp hover)` | Hover provider via `(sigil docs)` |
+22
| `(sigil lsp completion)` | Completion provider via `(sigil docs)` |
+23
| `(sigil lsp definition)` | Go-to-definition via module resolution |
+24
| `(sigil lsp formatting)` | Document and range formatting via `(sigil format)` |
+25
| `(sigil lsp code-actions)` | Quick-fix code actions (import, unused import) |
+26
| `(sigil lsp lint)` | Lint warnings carrying source positions |
+27
| `(sigil lsp commands)` | `sigil lsp` CLI subcommand registration |
+28
+29
## Usage
+30
+31
```scheme
+32
(import (sigil lsp))
+33
(lsp-serve)
+34
(lsp-serve log-file: "/tmp/sigil-lsp.log" log-level: 'debug)
+35
```
+36
+37
Or from the command line via sigil-cli:
+38
+39
```
+40
sigil lsp serve
+41
sigil lsp serve --log-file /tmp/sigil-lsp.log --log-level debug
+42
```
+43
+44
## Build and test
+45
+46
```
+47
sigil deps install
+48
sigil build
+49
sigil test --report
+50
```
+51
+52
Local development against an unreleased sigil monorepo:
+53
+54
```
+55
sigil deps install --redirects ./dev-redirects.sgl
+56
sigil build --redirects ./dev-redirects.sgl
+57
```
+58
+59
## License
+60
+61
BSD-3-Clause. See `LICENSE` in the sigil monorepo for the canonical copy.
dev-redirects.sgladded
@@ -0,0 +1,13 @@
+1
;; Development redirects — point from-git deps at local sibling checkouts
+2
;; during monorepo dev. Use: sigil build --redirects ./dev-redirects.sgl
+3
(redirects
+4
repos: (list
+5
(for-repo
+6
url: "codeberg:sigil/sigil"
+7
use: (from-path dir: "../sigil"))
+8
(for-repo
+9
url: "codeberg:sigil/sigil-json"
+10
use: (from-path dir: "../sigil-json"))
+11
(for-repo
+12
url: "codeberg:sigil/sigil-log"
+13
use: (from-path dir: "../sigil-log"))))
manifest.scmadded
@@ -0,0 +1,7 @@
+1
;; sigil-lsp Development Environment
+2
;; Use with: guix shell -m manifest.scm
+3
+4
(specifications->manifest
+5
'("gcc-toolchain"
+6
"make"
+7
"pkg-config"))
package.sglmodified
@@ -6,16 +6,17 @@
6
7
(package
8
name: "sigil-lsp"
+9
version: "0.13.1"
10
description: "Language Server Protocol implementation for Sigil"
10
url: "https://codeberg.org/sigil/sigil"
+11
url: "https://codeberg.org/sigil/sigil-lsp"
12
license: "BSD-3-Clause"
13
authors: (list "David Wilson <[email protected]>")
14
15
dependencies: (list
15
(from-workspace name: "sigil-stdlib")
+16
(from-git url: "codeberg:sigil/sigil" package: "sigil-stdlib" version: "^0.13.1")
17
(from-git url: "codeberg:sigil/sigil-json" version: "^0.13.1")
18
(from-git url: "codeberg:sigil/sigil-log" version: "^0.13.0")
18
(from-workspace name: "sigil-ansi")
19
(from-workspace name: "sigil-args")
20
(from-workspace name: "sigil-format")
21
(from-workspace name: "sigil-docs")))
+19
(from-git url: "codeberg:sigil/sigil" package: "sigil-ansi" version: "^0.13.1")
+20
(from-git url: "codeberg:sigil/sigil" package: "sigil-args" version: "^0.13.1")
+21
(from-git url: "codeberg:sigil/sigil" package: "sigil-format" version: "^0.13.1")
+22
(from-git url: "codeberg:sigil/sigil" package: "sigil-docs" version: "^0.13.1")))
sigil.lockadded
@@ -0,0 +1,38 @@
+1
;; Auto-generated by sigil deps install. Do not edit.
+2
(lock
+3
(package name: "sigil-stdlib"
+4
url: "codeberg:sigil/sigil"
+5
ref: "^0.13.1"
+6
sha: "1aea1cecd3487bf07d071da2c1e7eb3cf4bbdb21"
+7
package-selector: "sigil-stdlib")
+8
(package name: "sigil-json"
+9
url: "codeberg:sigil/sigil-json"
+10
ref: "^0.13.1"
+11
sha: "811b63925399a663e4b7dd25fb0813d59d33f557"
+12
version: "0.13.1")
+13
(package name: "sigil-log"
+14
url: "codeberg:sigil/sigil-log"
+15
ref: "^0.13.0"
+16
sha: "44aa809a421be278e7a9c0d692b65d01b576c53f"
+17
version: "0.13.0")
+18
(package name: "sigil-ansi"
+19
url: "codeberg:sigil/sigil"
+20
ref: "^0.13.1"
+21
sha: "1aea1cecd3487bf07d071da2c1e7eb3cf4bbdb21"
+22
package-selector: "sigil-ansi")
+23
(package name: "sigil-args"
+24
url: "codeberg:sigil/sigil"
+25
ref: "^0.13.1"
+26
sha: "1aea1cecd3487bf07d071da2c1e7eb3cf4bbdb21"
+27
package-selector: "sigil-args")
+28
(package name: "sigil-format"
+29
url: "codeberg:sigil/sigil"
+30
ref: "^0.13.1"
+31
sha: "1aea1cecd3487bf07d071da2c1e7eb3cf4bbdb21"
+32
package-selector: "sigil-format")
+33
(package name: "sigil-docs"
+34
url: "codeberg:sigil/sigil"
+35
ref: "^0.13.1"
+36
sha: "1aea1cecd3487bf07d071da2c1e7eb3cf4bbdb21"
+37
package-selector: "sigil-docs")
+38
)