zed/crates/collab
Antonio Scandurra ef784cf21e Remove summaries that don't contain any errors or warnings
When opening a buffer, some language servers might start reporting
diagnostics. When closing a buffer, they might report that no diagnostics
are present for that buffer. Previously, we would keep an empty summary entry
which would cause us to open a buffer in the project diagnostics view, only to
drop it because it contained no diagnostics. However, the act of opening it
caused the language server to asynchronously report non-empty diagnostics.
We would therefore handle this as an update, but the previous closing of the
buffer would cause the language server to report empty diagnostics again. This
would cause the project diagnostics view to thrash infinitely between these two
states, pegging the CPU and constantly refreshing the UI.

With this commit we won't maintain empty summary entries for files that contain
no diagnostics, which fixes the above issue.

Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-04-19 15:30:46 +02:00
..
k8s Update certificate 2022-04-11 18:33:55 -06:00
migrations Rename zed-server to collab 2022-04-09 08:30:42 -06:00
src Remove summaries that don't contain any errors or warnings 2022-04-19 15:30:46 +02:00
static Rename zed-server to collab 2022-04-09 08:30:42 -06:00
templates Rename zed-server to collab 2022-04-09 08:30:42 -06:00
.env.template.toml Rename zed-server to collab 2022-04-09 08:30:42 -06:00
basic.conf Rename zed-server to collab 2022-04-09 08:30:42 -06:00
Cargo.toml Merge branch 'main' into randomized-test-improvements 2022-04-12 10:14:08 +02:00
favicon.ico Rename zed-server to collab 2022-04-09 08:30:42 -06:00
Procfile Rename zed-server to collab 2022-04-09 08:30:42 -06:00
README.md Rename zed-server to collab 2022-04-09 08:30:42 -06:00
styles.css Rename zed-server to collab 2022-04-09 08:30:42 -06:00

Zed Server

This crate is what we run at https://zed.dev.

It contains our web presence as well as the backend logic for collaboration, to which we connect from the Zed client via a websocket.

Templates

We use handlebars templates that are interpreted at runtime. When running in debug mode, you can change templates and see the latest content without restarting the server. This is enabled by the rust-embed crate, which we use to access the contents of the /templates folder at runtime. In debug mode it reads contents from the file system, but in release the templates will be embedded in the server binary.

Static assets

We also use rust-embed to access the contents of the /static folder via the /static/* route. The app will pick up changes to the contents of this folder when running in debug mode.

CSS

This site uses Tailwind CSS, which means our stylesheets don't need to change very frequently. We check static/styles.css into the repository, but it's actually compiled from /styles.css via script/build-css. This script runs the Tailwind compilation flow to regenerate static/styles.css via PostCSS.