The language server
for smart contracts.
ForgeLS speaks Language Server Protocol over stdio. Diagnostics, hover, completion, and goto-definition for Solidity — in any LSP-capable editor, with zero editor plugins.
$ cargo install --path crates/forgelsWorks with your editor
Any LSP client. No editor-specific plugin required.
Everything an LSP should do
Diagnostics that keep up
Debounced publish on every keystroke, cleared when the file closes. UTF-16 positions your editor understands.
Hover and goto-definition
Types, NatSpec docs, and jump-to-declaration — including symbols imported from other files.
Completion everywhere
Contract members, in-scope symbols, builtin types, and cross-file exports with origin hints.
Multi-file project index
Imports rebuild the project index on open and change. Dependents refresh when a target edits.
Foundry-aware remappings
Reads foundry.toml remappings and libs layout, so forge-std imports resolve out of the box.
Multi-root workspaces
Strict LSP lifecycle across workspace folders. Stale roots are evicted, never haunt you.
Configured in code, not clicks
One binary, one optional TOML file. Point your editor at forgels over stdio and you are done.
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
contract Counter {
uint256 public total;
function add(uint256 amount) public {
total += amount;
}
}Built in the open
ForgeLS is MIT/Apache-2.0 Rust, developed as a workspace of small focused crates. Solidity today, Noir and Cairo next.
Star on GitHub
ForgeLS