Newsboat's authors are rewriting it in Rust. They concluded (last time I checked) that C and some early design decisions were bad for its development now and they want to rewrite it in Rust because this is something that can be done gradually (and, I think, because they liked Rust). Before they settled down with Rust, they even considered Haskell, but Rust won.
Surprising that this project is in C. Given a chance to start fresh, why not choose a better language? Even Rust, I think, is unnecessarily low-level for an applied, not performance-critical program like an RSS reader. That's why I chose Haskell. Any other high-level programming language would be a better choice than C.
> Newsboat's authors are rewriting it in Rust. They concluded (last time I checked) that C and some early design decisions were bad for its development now and they want to rewrite it in Rust because this is something that can be done gradually (and, I think, because they liked Rust). Before they settled down with Rust, they even considered Haskell, but Rust won.
There seems to be a common pattern that people believe "program that compiles to binary suffers from segfaults, therefore use Rust". Rust will not fix your poorly designed code, now it is harder to develop and runs slower. Your broken logic is still broken.
> Surprising that this project is in C. Given a chance to start fresh, why not choose a better language? Even Rust, I think, is unnecessarily low-level for an applied, not performance-critical program like an RSS reader. That's why I chose Haskell. Any other high-level programming language would be a better choice than C.
The code could do with some comments, but it's otherwise clean. It has been mostly worked on by Grigory Kirillov [1] and maybe this is a language they like [1]. Given the use of `func_name(void)` and `int64_t` it seems like somebody quite capable of writing C safely. With some regression testing this could be a fast and reliable program.
> Rust will not fix your poorly designed code
Nobody said it will. But segfaults hardly come from poor design. They come from accidental mistakes, lack of static analysis, and gotchas that your language offers.
> now it is harder to develop
Only if you're a C programmer who doesn't know Rust.
> and runs slower
This is plan false. Please back it up.
> it seems like somebody quite capable of writing C safely
Try using it for a week, and count for me how many times it segfaults on your face. (That is not to diminish Grigory's work, which I have nothing against.)
Hi, Newsraft developer here. Not that I was offended, but I just wanted to let you know that I use it daily and don't encounter segfaults with builds from release tarballs like at all. I'm trying to leave tag commits as clean as possible, but I admit that logical bugs can slip through :)
Anybody can submit a patch to the Linux kernel (which is great of course). Any big names (long term kernel development) backing it?
That said, kernel development has different constraints to userspace application development. For kernel drivers for example, sometimes you really are pulling absolutely every trick out of the book just to squeeze enough performance out.
> Nobody said it will. But segfaults hardly come from poor design. They come from accidental mistakes, lack of static analysis, and gotchas that your language offers.
Sure, but there are a few simple patterns when used throughout that are quite reliable. There are quite a few books out there on writing safe and reliable C.
> > now it is harder to develop
> Only if you're a C programmer who doesn't know Rust.
Maybe, but I'm not yet sold that the added 'dance' you have to perform with Rust is worth excluding one type of bug.
> > and runs slower
> This is plan false. Please back it up.
Every C program can theoretically [+] be compiled to be the same as a Rust binary, but not every Rust program could be compiled to be the same as a C binary [1].
> Try using it for a week, and count for me how many times it segfaults on your face. (That is not to diminish Grigory's work, which I have nothing against.)
I use it quite regularly. Even more regularly I use C++, I simply program with it in the same way one would do using Java as pure OO and no raw pointer magic (except in rare, well tested cases). The less magic used, the more reusable your code will be in the future.
[+] Not exactly, but close enough.
[1] https://benchmarksgame-team.pages.debian.net/benchmarksgame/...
As replied in another comment, here it is. Enjoy!
> "It is a rewrite in Go of the wonderful, but unfortunately now unmaintained"
Is it still working? If not, I might need to read up on the IMAP protocol... Could be cool to hack such a thing together.
One feature I would suggest is to import an OPML file to help those (like me) with insane numbers of existing RSS feeds.
Yes. Your sentence misses a comma and a word: feed2imap is (more or less) unmaintained, therefore I rewrote it in Go, resulting in feed2imap-go
> One feature I would suggest is to import an OPML file to help those (like me) with insane numbers of existing RSS feeds.
Please feel free to open an issue. Note: Import does not make that much sense, but writing a generator that spits out the yaml file (or portion thereof) could be useful.
Yeah I saw this after, no idea why I read that wrong. First thing I do when I see a repo is try to figure out if it's being actively developed and if that makes a difference.
> Please feel free to open an issue. Note: Import does not make that much sense, but writing a generator that spits out the yaml file (or portion thereof) could be useful.
I did think after that this might be something suitable for a small Python script. I don't know any Go (and am too busy too learn), otherwise I would hack it together myself.
Personally, I prefer using one that renders HTML and shows pictures :)
Some just prefer simple and minimalist software for their daily life, and there's no place for the Rust ecosystem there. For this reason projects like dwm, st, dmenu, bspwm, sxcs, sxhkd, nsxiv, xmenu, xplugd, fzy, nnn, xbanish, scdoc and many others will never be rewritten in Rust or adopted by users who strive for simplicity rather than colorful terminal output. memory safety is just not worth it.
Judging by this list [0] even Python or Go have more chances to align with the philosophy that encourages building simple yet functional things. And I hope this trend of fresh starts continues.
Sure it's a bit silly to rewrite a nice simple tool for because it's the new fad. However if writing a new simple tool I'd certainly consider Rust.
How is Rust incompatible with aligning with the philosophy that encourages building simple yet functional things?
This was more of a sarcastic reference to https://github.com/mTvare6/hello-world.rs But I don't think Rust fits in here: https://suckless.org/philosophy/
> How is Rust incompatible with aligning with the philosophy that encourages building simple yet functional things?
I would say it attracts different kind of developers that in turn make respective design choices, and I believe Rust, its syntax, package management ecosystem and community reflect that. Can you write simple system tools in JavaScript or brainfuck (not trying to compare here)? Sure, but the thinking process, design decisions, approaches would be drastically different compared to what I'd consider good and elegant code.
ANSI C is probably the best balance you can get between product complexity, coding complexity and usability of the output (which again, has to be simple: writing something like Kubernetes in C is probably not the best idea, hence it was implemented in a more suitable language). Though there are some very good and complex products, like the Linux kernel, Redis or Varnish. All of them are very modular, as complex products should be.
Just by having a musl library and tcc [0] you can get a lot done. I'd prefer that over complexity that Rust toolchain involves and crates ecosystem mess.
> Third-party Apps
> Free Account: Up to 64 sites, doesn't show the full text of the article
> Premium Subscription
> No desktop app
Really?