Coder Social home page Coder Social logo

bazel-lsp's Introduction

Bazel LSP

This is a LSP for bazel, based on starlark-rust.

Features

  • Go to definition for identifiers & labels
  • Autocomplete for identifiers & labels
  • Auto-import (currently only for open files)

Usage

Installation

Download a release from github releases and move it to somewhere on your $PATH.

Alternatively, it can be installed from source by cloning this repo and building with Bazel:

bazel build //:bazel-lsp -c opt

VSCode

Ensure you have the Bazel extension installed, and add the following config to your user settings.json:

{
  "bazel.lsp.command": "bazel-lsp"
}

Restart vscode for this to take effect.

bazel-lsp's People

Contributors

cameron-martin avatar stepancheg avatar jakobdegen avatar

Stargazers

Alexander Strogy avatar lasorda avatar  avatar Ivan Persidsky avatar Akmal avatar fwcd avatar Rahul Butani avatar  avatar Irwan Fario Subastian avatar  avatar Adrian Vogelsgesang avatar Artem Yarmoliuk avatar Danilo Cianfrone avatar Marc Redemske avatar Nick Mazuk avatar Matthew Benson avatar Timo Furrer avatar Josiah Saunders avatar Vinh Tran avatar Alberto Cavalcante avatar Łukasz Kurowski avatar Kevin Le avatar Nils Wireklint avatar Daniel Kongsgaard avatar Laurent Le Brun avatar Son Luong Ngoc avatar  avatar  avatar Ezekiel Warren avatar

Watchers

Laurent Le Brun avatar Nils Wireklint avatar  avatar Johan avatar Adrian Vogelsgesang avatar Vinh Tran avatar  avatar

Forkers

dtolnay-contrib

bazel-lsp's Issues

Preserve output bases between language server restarts

75b9306 introduced a distinct output base for querying. However, it uses a temp directory that is deleted after the language server shuts down. This directory is potentially quite expensive to create, so destroying it is not ideal. Instead, we should put it in a permanent location, in a directory named after the hash of the workspace directory.

E2E tests

Just testing the LspContext is not sufficient, particularly for picking up regressions caused by upstream, or integration issues. We should have tests that exercise the whole server.

Add type information to builtins

#8 added autocomplete to builtins but typed everything as any. We can do better than this since there's a bunch of type information in the protobuf.

Release for more platforms

Currently it only uploads x86 Linux builds. We should do this for more platforms, for example:

  • Mac M1
  • Mac x86
  • Windows x86

Add cc, py and java builtins

#8 added some builtins, but this proto does not include things like cc_library. I'm not sure where these are meant to come from.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.