zed icon indicating copy to clipboard operation
zed copied to clipboard

Dart support

Open agent3bood opened this issue 1 year ago โ€ข 9 comments
trafficstars

This is my first contribution, feedback is welcome.

Release Notes:

  • Added Dart language support (#5343).

agent3bood avatar Feb 01 '24 15:02 agent3bood

We require contributors to sign our Contributor License Agreement, and we don't have @agent3bood on file. You can sign our CLA at https://zed.dev/cla. Once you've signed, post a comment here that says '@cla-bot check'.

cla-bot[bot] avatar Feb 01 '24 15:02 cla-bot[bot]

@cla-bot check

agent3bood avatar Feb 01 '24 15:02 agent3bood

The cla-bot has been summoned, and re-checked this pull request!

cla-bot[bot] avatar Feb 01 '24 15:02 cla-bot[bot]

Hey @agent3bood thanks a lot , was really waiting for it

Aarush-Acharya avatar Feb 01 '24 15:02 Aarush-Acharya

Like the CI, I am having issues building:

$ cargo run --release

    Updating crates.io index
    Updating git submodule `[email protected]:tree-sitter/tree-sitter`
error: failed to get `tree-sitter-dart` as a dependency of package `zed v0.122.0 (/Users/brettmorgan/Documents/GitHub/zed/crates/zed)`

domesticmouse avatar Feb 04 '24 02:02 domesticmouse

This is my first contribution, feedback is welcome.

Release Notes:

  • Added Dart language support (#5343).

Waiting for this to be merged soon, hopefully!

imujtaba8488 avatar Feb 05 '24 05:02 imujtaba8488

can't wait for the merge and then to use flutter with ZED.

TheGlorySaint avatar Feb 05 '24 16:02 TheGlorySaint

Building works on my machine, could it be related to CI not having github in known_hosts? Or ssh key not setup?

agent3bood avatar Feb 05 '24 17:02 agent3bood

Building works on my machine, could it be related to CI not having github in known_hosts? Or ssh key not setup?

Yeah, I don't have SSH keys setup. The more interesting question is, why is the CI failing? Surely they have SSH keys setup for the CI bots?

domesticmouse avatar Feb 05 '24 21:02 domesticmouse

Made a fork to fix some issues in the original tree-sitter-dart, should work now.

agent3bood avatar Feb 06 '24 19:02 agent3bood

Looks like all checks have passed. Could we get it in?

imujtaba8488 avatar Feb 07 '24 07:02 imujtaba8488

hey guys what is missing from this just read this like a rollercoster of emotion

user-23xyz avatar Feb 10 '24 06:02 user-23xyz

@agent3bood Thanks for the PR! Can you rebase or merge main?

Also, could you include screenshots of the syntax highlighting and outline view?

Just a heads up - we are very soon going to be moving most of Zed's built-in languages into installable extensions (https://github.com/zed-industries/zed/issues/7096). Dart is a major enough language that I'm ok with merging this in the meantime. But once the extension system lands, we will probably remove this code and put it into a new dart repository under the new zed-extensions GitHub org. We'll probably add you as a collaborator on that repo when we do it, if you're interested in helping maintain it.

maxbrunsfeld avatar Feb 10 '24 18:02 maxbrunsfeld

@maxbrunsfeld done, looking forward for getting this merged and contributing even more to the project.

Screenshot 2024-02-12 at 13 17 46

agent3bood avatar Feb 12 '24 10:02 agent3bood

Wow. Finally. <3

murshid1988 avatar Feb 12 '24 15:02 murshid1988

Huge thanks for this effort!

As soon as this gets merged in, I am poised to give Zed a try. Getting a bit tired of the slowness of VSCode.

LiamHockley avatar Feb 12 '24 20:02 LiamHockley

@maxbrunsfeld Updated the highlights as suggested. Also check the file outline view bellow.

Screenshot 2024-02-13 at 11 12 08

agent3bood avatar Feb 13 '24 08:02 agent3bood

LGTM

ebsangam avatar Feb 14 '24 05:02 ebsangam

Let's gooo ๐Ÿš€๐Ÿš€๐Ÿš€

ebabhi avatar Feb 14 '24 10:02 ebabhi

Let's gooo ๐Ÿš€๐Ÿš€๐Ÿš€

repeat > Lets' go ๐Ÿš€๐Ÿงจ

imujtaba8488 avatar Feb 15 '24 07:02 imujtaba8488

When ship? ๐Ÿšข๐Ÿšข๐Ÿšข

ebsangam avatar Feb 16 '24 02:02 ebsangam

When ship? ๐Ÿšข๐Ÿšข๐Ÿšข

with extensions in pre (love it) - Lets' go for Flutter! ๐Ÿš€๐Ÿš€๐Ÿš€

imujtaba8488 avatar Feb 16 '24 06:02 imujtaba8488

we all agree that this will change the course of the human timeline right ?

user-23xyz avatar Feb 16 '24 19:02 user-23xyz

As Dart developers we're all excited about this. Please stop spamming the issue - and in general only comment on Github issues if you contribute to solving it in some meaningful way.

erf avatar Feb 16 '24 19:02 erf

ready ๐Ÿš€ CleanShot 2024-02-19 at 5โ€ฏ 01 04@2x

castletaste avatar Feb 19 '24 13:02 castletaste

@agent3bood Just my opinion: downgrade to a extensions: https://github.com/zed-industries/extensions

d1y avatar Feb 19 '24 15:02 d1y

@agent3bood Just my opinion: downgrade to a extensions: https://github.com/zed-industries/extensions

Looks like that will be the better option, just need a couple of days to check it out.

agent3bood avatar Feb 19 '24 15:02 agent3bood

Looks like zed extensions does not support adding language server to the editor, we will wait for this to be merged.

Languages Extensions may provide languages to extend Zed with support for a particular language. Currently this is used for things like syntax highlighting and outlining. Support for defining language servers in extensions will be coming in the future.

agent3bood avatar Feb 19 '24 17:02 agent3bood

Yes, we can move this into an extension later, once we have the extension APIs needed for adding new language servers. Thanks for your work on this @agent3bood.

maxbrunsfeld avatar Feb 19 '24 19:02 maxbrunsfeld

This will ship in Zed 0.124.

maxbrunsfeld avatar Feb 19 '24 19:02 maxbrunsfeld