aboutsummaryrefslogtreecommitdiff
path: root/content/posts/2023-05-22-crafting-stories-in-zed-editor.md
diff options
context:
space:
mode:
authorMitja Felicijan <mitja.felicijan@gmail.com>2023-06-27 14:50:20 +0200
committerMitja Felicijan <mitja.felicijan@gmail.com>2023-06-27 14:50:20 +0200
commit8697555125c57ae64a0c9b78514b4aac4fd523de (patch)
treea699df53a7c35a4425f30bca86982c4341f6de40 /content/posts/2023-05-22-crafting-stories-in-zed-editor.md
parent33b2615a5038bc85036081e8b5e0da8584d88097 (diff)
downloadmitjafelicijan.com-8697555125c57ae64a0c9b78514b4aac4fd523de.tar.gz
Massive formatting and added figcaption
Diffstat (limited to 'content/posts/2023-05-22-crafting-stories-in-zed-editor.md')
-rw-r--r--content/posts/2023-05-22-crafting-stories-in-zed-editor.md81
1 files changed, 40 insertions, 41 deletions
diff --git a/content/posts/2023-05-22-crafting-stories-in-zed-editor.md b/content/posts/2023-05-22-crafting-stories-in-zed-editor.md
index f5240da..ead4276 100644
--- a/content/posts/2023-05-22-crafting-stories-in-zed-editor.md
+++ b/content/posts/2023-05-22-crafting-stories-in-zed-editor.md
@@ -5,37 +5,38 @@ date: 2023-05-22T12:00:00+02:00
5draft: false 5draft: false
6--- 6---
7 7
8Pretentious title! Good start! I have nothing to add to this discussion. I just 8Pretentious title! Good start! I have nothing to add to this discussion. I just
9like this editor and wanted to write something here that will remind me to 9like this editor and wanted to write something here that will remind me to use
10use it again in a while when/if it becomes available for Linux. 10it again in a while when/if it becomes available for Linux.
11 11
12**TLDR:** I think this code editor is very cool and has a massive potential. 12**TLDR:** I think this code editor is very cool and has a massive potential. I
13I hope they don’t mess up with adding a plugin ecosystem to it! 13hope they don’t mess up with adding a plugin ecosystem to it!
14 14
15Out of morbid curiosity, I started using the [Zed editor](https://zed.dev/) 15Out of morbid curiosity, I started using the [Zed editor](https://zed.dev/) on
16on my Mac. Zed is a high-performance, multiplayer code editor developed by 16my Mac. Zed is a high-performance, multiplayer code editor developed by the
17the creators of Atom and Tree-sitter. Written in Rust so it has to be 17creators of Atom and Tree-sitter. Written in Rust so it has to be blazingly
18blazingly fast! 😊 It's a joke, calm down. 18fast! 😊 It's a joke, calm down.
19 19
20Over the past year, I have switched between [Helix editor](https://helix-editor.com/) 20Over the past year, I have switched between [Helix
21and [VS Code](https://code.visualstudio.com/), but for the last couple of 21editor](https://helix-editor.com/) and [VS
22months, I have been using Helix exclusively. 22Code](https://code.visualstudio.com/), but for the last couple of months, I have
23been using Helix exclusively.
23 24
24I've been genuinely impressed by Zed. When you open a file, it automatically 25I've been genuinely impressed by Zed. When you open a file, it automatically
25detects its type and downloads the corresponding [LSP (language server)](https://en.wikipedia.org/wiki/Language_Server_Protocol). 26detects its type and downloads the corresponding [LSP (language
26The list of supported languages is not extensive, but it's still impressive. 27server)](https://en.wikipedia.org/wiki/Language_Server_Protocol). The list of
27It's a great example of how to create a product that stays out of your way. 28supported languages is not extensive, but it's still impressive. It's a great
29example of how to create a product that stays out of your way.
28 30
29![Zed 1](/assets/zed/zed-1.png?style=bigimg) 31![Zed editor](/assets/zed/zed-1.png?style=bigimg)
30 32
31For C development it downloaded [clangd](https://clangd.llvm.org/) and setting 33For C development it downloaded [clangd](https://clangd.llvm.org/) and setting
32up missing dependencies in code was rather easy. For this project I use 34up missing dependencies in code was rather easy. For this project I use
33[SDL2](https://www.libsdl.org/) for rendering terminal emulator. It’s a 35[SDL2](https://www.libsdl.org/) for rendering terminal emulator. It’s a hobby
34hobby project, don’t worry about it. 36project, don’t worry about it.
35 37
36If you are going to give this a try and you are using C, I suggest checking 38If you are going to give this a try and you are using C, I suggest checking two
37two files in the root of your project folder. If you don't have them, 39files in the root of your project folder. If you don't have them, create them.
38create them.
39 40
40**compile_flags.txt** 41**compile_flags.txt**
41 42
@@ -44,10 +45,9 @@ create them.
44-I/opt/homebrew/include/SDL2 45-I/opt/homebrew/include/SDL2
45``` 46```
46 47
47Easy way of checking what the appropriate includes for a specific library is 48Easy way of checking what the appropriate includes for a specific library is to
48to use `pkg-config` and in my case `pkg-config SDL2 --cflags-only-I`. But this 49use `pkg-config` and in my case `pkg-config SDL2 --cflags-only-I`. But this is
49is nothing new to C/C++ devs. Just a noter for people who are using Visual 50nothing new to C/C++ devs. Just a noter for people who are using Visual Studio.
50Studio.
51 51
52**.clang-format** 52**.clang-format**
53 53
@@ -58,31 +58,30 @@ BasedOnStyle: Mozilla
58 58
59I prefer Mozilla coding style for C so you can set that up. 59I prefer Mozilla coding style for C so you can set that up.
60 60
61They really have something special here. Although there is no version available 61They really have something special here. Although there is no version available
62for Linux yet, I will stick to Helix. This impressive piece of engineering is, 62for Linux yet, I will stick to Helix. This impressive piece of engineering is,
63above all, an amazing example of craftsmanship. 63above all, an amazing example of craftsmanship.
64 64
65They have a bunch of amazing integrated functionalities like live desktop 65They have a bunch of amazing integrated functionalities like live desktop
66sharing, code sharing in a live coding session. There is a lot of pretentious 66sharing, code sharing in a live coding session. There is a lot of pretentious
67marketing speak there but the product is still amazing! 67marketing speak there but the product is still amazing!
68 68
69For me the speed and the simplicity of the product was the most impressive 69For me the speed and the simplicity of the product was the most impressive
70thing. You get that: it just works feeling. A rare thing in 2023. 70thing. You get that: it just works feeling. A rare thing in 2023.
71 71
72![Zed 2](/assets/zed/zed-2.png?style=bigimg) 72![Zed editor](/assets/zed/zed-2.png?style=bigimg)
73 73
74They also managed to add [Github Copilot](https://github.com/features/copilot) 74They also managed to add [Github Copilot](https://github.com/features/copilot)
75in a non obtrusive way. To me, everything feels very intentional and 75in a non obtrusive way. To me, everything feels very intentional and
76specifically selected. It's minimal yet maximally effective. 76specifically selected. It's minimal yet maximally effective.
77 77
78<video src="https://zed.dev/img/post/copilot/copilot-demo.webm" autoplay loop></video> 78<video src="https://zed.dev/img/post/copilot/copilot-demo.webm" autoplay loop></video>
79 79
80It is a perfect balance between VS Code, Jetbrains IDE’s and something like 80It is a perfect balance between VS Code, Jetbrains IDE’s and something like VIM
81VIM or Helix. 81or Helix.
82 82
83I just hope they **DON’T** add plugin support and keep it like it is. They as a 83I just hope they **DON’T** add plugin support and keep it like it is. They as a
84vendor should add stuff to it with great deliberation and thought. And this 84vendor should add stuff to it with great deliberation and thought. And this way
85way the product will stay fast and focused. That’s my two cents. 85the product will stay fast and focused. That’s my two cents.
86 86
87Amazing job! 87Amazing job!
88