by Meekro · 7mo ago · 0 comments
For each kind of warning, I wish there was a button that said "don't warn me again about issues like this one in this project." Then I could keep the interesting warnings (like undeclared variable) and ditch the ridiculous ones.
Isn't it just the default configuration of whatever LSP zed defaults to for PHP?
So you should be able to either configure the LSP to avoid that or disable the LSP server entirely.
however, i think LSP or integrated linters/typecheckers have been standard fare in editors for a while now (zed does seem to have a lot more set up by default, but i like the sane defaults most of the time). The "correct" solution would be to configure whatever lsp zed is running for the project the way you want, and reap the benefits even outside of zed. for php the tools are listed here: https://zed.dev/docs/languages/php the main one seems to be Phpactor and you should be able to configure it globally or per project https://phpactor.readthedocs.io/en/master/usage/configuratio...
but i understand the frustration, sometimes i try to navigate an ancient python codebase and it really is a sea of red
The landscape isn't generally intuitive, unfortunately, and while it's getting better, understanding the differences and interop places between LSP, Treesitter, DAP, your editor, and the underlying language-specific tooling can be a big, confusing time hog.
That said, and to be clear: LSP's been a huge boon for me. I used a minimal, kinda-broken configuration for a while with Python, then rebuilt the whole thing when I switched to Rust for work, and holy hell, this thing's awesome.
[1]: https://code.claude.com/docs/en/plugins-reference#lsp-server...
Edit for clarity: I want to fully switch to Zed, I really like it and their vision for the editor. PHP issues are a hurdle, not a turnoff to me.
I feel like some people will be put off by all the "AI" mentioned by Zed, but you're sleeping on a top tier editor where you can just ignore the AI stuff if you don't want it. It's very high quality, and probably the reason I wont be renewing next year for JetBrains, unless JetBrains does something impressive, I thought by now they'd have a more native feeling IDE that handles most / any language instead of so many separate ones.
VS Code has gotten so bloated over the years. The gold standard of ST has spoiled me with simpler editors. Zed is the first time I felt like someone finally built an editor that is modern and has a rich set of features.
I don't know what your financial situation is, but given that the upgrade is an $80 one off payment (a new license is $99), that it's a per-user license (not per-machine), and that there were 8 years between Sublime Text 3 (2013) and Sublime Text 4 (2021) (only major versions require a new license), I personally think it's very reasonably priced.
That said, there are a lot of reasons why someone might be struggling with money. If I was the creator, I wouldn't object to someone using an unlicensed copy forever in that case.
You are however limited to 3 years of updates, so if you want to keep up to date, it is $80 for 3 years. Which if fine for me, it is the one piece of software I used the most except for the browser and OS, I even use it to make money, $80 / 3 years is not much.
It is also the kind of software I like to support. It is... respectful in that it isn't a resource hog, runs fast, launches fast, and it doesn't try to be anything but a text editor. No ads, no subscription, no cloud, no AI, no slop, no dark patterns, no enshittification. Just an executable that does what it say it will do, and does it well. I wish it was open source, but it works well enough out of the box to not need it.
I do suggest people pay though, it's cheap for a one-time purchase. The only reason I've ever seen the message at all is because I spent months being too lazy to dig up the license key to send to my work email. (That should also say something about how little I was being bothered by the message too)
This is even higher CPU usage than my vscode causes.
Sublime does not do that; in fact it has 0% CPU usage when idle:
sudo strace -fyp "$(pidof sublime_text)"
shows that Sublime issues no syscalls when idle, as it should be.(Note, you need to either unfocus it so that the caret stops flashing, or switch from fading caret to fixed / non-fading caret, otherwise it necessarily has to do syscalls to draw itself.)
Zed spams syscalls even when its screen is entirely still:
strace -fyp "$(pidof zed-editor)"
In fact Zed makes 800 syscalls per second when completely idle and unfocused.Good software does not do that; when idle, it should only consume RAM, not CPU.
Aside: Browsers, and Electron, seem to always syscall-spam no matter what, which is probably a key reason why people feel that all Electron apps bog down their computers. When your computer gets faster, the software just does more syscall loops per second, for unchanged misery.
It's like how a video game renders, which is their stated goal from the beginning.
I always thought their stated design goals were a bit... wonky.
I'm running on a Zed with only 1 empty text file in it. So language servers should not be in use.
How do you measure "pretty lightweight"?
I use it every day. The #1 reason is because it never loses unsaved files (though I'm still working on breaking the habit of typing a few characters and pressing Ctrl-S). Column editing! Macros! Record/Playback! Configuration! Plugins! Responsiveness! Low resource utilization! Etc!
Why wouldn't I pay for it? I've bought all four versions. The author deserves to be paid.
I guess the question is: why don't you want to pay for it? Assuming here that you're a professional coder being paid a reasonable, US-equivalent salary. I understand not everyone fits that situation; plenty of us pirated software as starving college students / interns, folks in other countries don't get the same pay for the same work, etc.
We should all want to pay the authors of great software. We're on HN, which is a celebration of creating great code and awesome businesses.
"Pay him. Pay that man his money" - Teddy KGB
This is a big one indeed. I keep many unsaved tmp notes and pastes open all the time. Sublime Text also have it's super smooth pane and window management, so easy to select many tabs, drag and drop tabs to windows etc. Never mind what is unsaved and not. Everything always there on open anyway.
I think this is a highly requested feature in Zed as well, but not sure if they are actually working on this or not.
Jetbrains is a heavyweight IDE, but I'm not sure if the weight is worth the features it offers anymore, at least for the things I work on.
VS Code is also an IDE, but it's a bit easier on resources depending on what plugins you use and what you allow them to do. I've had combinations of plugins that caused my whole system to freeze up with too much memory usage because it spawned several Node processes each taking up multiple GBs of memory :/.
I always called it a Lightweight IDE. ;)
I’m not sure why though. I do not have the issue you do, but Sublime feels better.
I'm sticking with Sublime Text, as its developers actually respect boundaries on my computer.
Yes. This is bad. Zed keeps installing and running all sorts of random background stuff. This should be an opt-in.
I eat the cost of configuring it manually when I start up something new because it's just not that big of deal, even when you're like me, working across myriad languages and frameworks and organization with varying standards. It's not ideal, but it's not deal-breaker.
I do wish that there was a better way to definitively set it up a particular way and know that it is doing what you want it to do. I want something like presets/profiles. If I'm working with typescript, I want to be able to set it up to use a specific version of tsc, eslint, prettier; I also want to be able to create a different one with biome; I want it to work correctly whether I have my source in the project root or in a sub directory or in a monorepo tree.
Fairness to Zed: it is difficult to support all of these permutations, but I do think that they ought to be able to do something better to abstract these things and make the reusable.
Even if it's for solo projects, it's nice that you don't have to update them in lockstep. As in, you revisit an older repo, you don't get bombarded with squiggly lines from your latest user profile, instead you can upgrade it at your leisure.
1. I want to be able to readily duplicate that configuration for another similar project.
2. It's not always appropriate to co-locate those specific files within the project source itself, especially within a source repository. Notable cases are if we're working on different platforms with different binary paths, or if we're not standardized on a particular editor. I should be able to configure my editor without polluting the common source.
I've tried Zed several times like this and it continues to lose data.
While there was a bug where the session was lost when updating, this was fixed years ago.
Are you sure? I believe Sublime preserves all your unsaved tabs even on update.
burned once, twice shy; i wouldnt update without spending an hour making up names for random junk files
Sublime also saves a backup of its state files next to the state files in your home dir, so you can restore in case anything ever goes wrong (e.g. bugs in the new version).
The .sublime_session state files are JSON, easy to read for a human.
> spending an hour making up names for random junk files
That is completely unnecessary. You can just backup the '.sublime_session' file that contains all that before an upgrade if you are worried. Sublime already stores all its state in 1 file; manually spreading that across N files seems unfun busywork. A quick web search reveals that by the way.
(I perpetually have 40 Sublime windows open, each one with tens to hundreds of tabs. My 'Auto Save Session.sublime_session' is 70 MB.)
You may be able to do this by editing a language server-specific config file in whatever arcane syntax they decided to offer. But there isn't any editor support for configuring languages servers, so it's a bit of a lift for a newcomer who just wants to turn off some warnings
Writing C in Zed is a wonderful experience. The LSPs surface errors in an manner that is very easy to view and edit.
My main issues with Zed are:
- Word-wrap: I prefer on-demand, and I haven't been able to figure out which setting triggers that. Of if it is even possible.
- Support for Devanagari and other scripts: I use it as a markdown editor to proofread old texts and it is inadequate for that purpose. Kate/Featherpad offers a superior experience for this, including the ability to zoom to see those visually difficult to parse conjunct consonants.
Glad I'm not the only one that frequently makes this typo.
I haven't used Zed, but can you choose the PHP version, or point to a PHP executable for warnings/errors? I know in VS Code, you point to the PHP executable for the version you are using, to catch errors. I haven't created a new PHP project in quite some time, but I did work on many older PHP projects, and never had this issue with VS Code. I suspect even if you don't go about it this way, there has to be configuration to specify what is and isn't an error vs. warning.
With Zed, I feel like I'm being dragged into a modern style guide that I never agreed to. It would be nicer if I could make it my own by turning off those parts that I disagree with and keeping the rest. I know this is technically possible, but they've certainly not made it easy.
It really there is no realy good ide or tools for php