Skip to content

Commit

Permalink
feat(nargo): Add lsp command to start server that reports no capabi…
Browse files Browse the repository at this point in the history
…lities (#1560)

* feat(nargo): Add lsp command to start server that reports no capabilities

* move async-lsp dep into crates to use different features

* cspell

* utilize pattern in matches

* handle shutdown and exit to make vscode plugin happy

* rename nargo_lsp to noir_lsp & move dir

* add lsp to the crates readme
  • Loading branch information
phated committed Jun 7, 2023
1 parent 905d39d commit e28529d
Show file tree
Hide file tree
Showing 9 changed files with 373 additions and 2 deletions.
127 changes: 127 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ fm = { path = "crates/fm" }
iter-extended = { path = "crates/iter-extended" }
nargo = { path = "crates/nargo" }
nargo_cli = { path = "crates/nargo_cli" }
noir_lsp = { path = "crates/lsp" }
noirc_abi = { path = "crates/noirc_abi" }
noirc_driver = { path = "crates/noirc_driver" }
noirc_errors = { path = "crates/noirc_errors" }
Expand All @@ -44,9 +45,11 @@ codespan-reporting = "0.9.5"
chumsky = { git = "https://github.com/jfecher/chumsky", rev = "ad9d312" }
dirs = "4"
serde = { version = "1.0.136", features = ["derive"] }
serde_json = "1.0"
smol_str = "0.1.17"
thiserror = "1.0.21"
toml = "0.7.2"
tower = "0.4"
url = "2.2.0"
wasm-bindgen = { version = "0.2.83", features = ["serde-serialize"] }
wasm-bindgen-test = "0.3.33"
17 changes: 17 additions & 0 deletions crates/lsp/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
[package]
name = "noir_lsp"
description = "Language server for Noir"
version.workspace = true
authors.workspace = true
edition.workspace = true

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
serde_json.workspace = true
tower.workspace = true
async-lsp = { version = "0.0.4", default-features = false, features = ["omni-trait"] }
lsp-types = "0.94"

[dev-dependencies]
tokio = { version = "1.0", features = ["macros"] }
Loading

0 comments on commit e28529d

Please sign in to comment.