... implemented in Rust!!! Having skimmed through quite a few Rust projects on Github lately I am overwhelmed by the amount of code in them. I feel lost looking at any random file, it's too OOP-y for me, I can't really see what it's doing.
I start to feel a little insecure about my own abilities, I've mostly focused on building small components or little systems from the ground (in C) up with minimal or no libraries. That works and is rewarding, until the project becomes unmanageable because of some aspect that I'd done poorly, and I start a new project that focuses on exploring the particular kind of subsystem that I didn't know how to do properly.
It also seems like the following is a pattern. I checked out that intimidating Rust project using git. It's something like 50MB to download. Then I run "cargo build". I wait 5-10 minutes and it is still "fetching". At some point, it goes on to compile 550 (!) transitive dependencies. A little while later, the build failed, could not compile libc, unicode-xid, cfg-if, proc-macro2. Not sure, maybe I have the wrong version of "cargo" installed?
I get back to my small current hobby project, which is somehow more rewarding to me since I can still check it out on a fresh Linux or Windows box, run "build.sh" and run it. That whole process can complete in 20 seconds.
Am I too stubborn? Or should a terminal emulator really be not such a massive project? (No offense meant).
>it's too OOP-y for me, I can't really see what it's doing
Eh, Rust doesn't have OOP. What do you mean? I get that Rust is a bit hard to read if you aren't used to it but apart from that it's fine for me. Don't forget that Rusts verbose-ness also stems from dealing with the borrow-checker which in turn gives you memory safety. Almost every C-project has memory bugs somewhere.
The thing with cargo: In general cargo is really painless, the first build does take long but after that build times are ok for most projects. You only run into problems with projects like servo which are huge.
build.sh scripts have to be managed by the author while cargo run magically works in basically any Rust project.
>Am I too stubborn? Or should a terminal emulator really be not such a massive project? (No offense meant).
Depends, this is not only an emulator but also a multiplexer. A simple terminal emulator that supports basic commands is a small program, I mean look suckless st. But if you get into suporting ligatures, UTF8 etc. you will get a lot more complexity that in turn adds code and dependencies.
I imagine properly supporting UTF8 and Ligatures in C would be a huge pain.
I really wish every rust project had a `rust-toolchain` file checked in[0]. This would cause rustup to automatically select the correct version of rust to use to build the project, thus making it easier to reproduce the build.
Would you like to submit a PR to add a suitable version of that file to wezterm?
FWIW, in my experience so far with wezterm, most people that have run into issues with old rust versions are not running rustup at all, so I feel like something rust/cargo should also have a mechanism to specify an appropriate version.
I start to feel a little insecure about my own abilities, I've mostly focused on building small components or little systems from the ground (in C) up with minimal or no libraries. That works and is rewarding, until the project becomes unmanageable because of some aspect that I'd done poorly, and I start a new project that focuses on exploring the particular kind of subsystem that I didn't know how to do properly.
It also seems like the following is a pattern. I checked out that intimidating Rust project using git. It's something like 50MB to download. Then I run "cargo build". I wait 5-10 minutes and it is still "fetching". At some point, it goes on to compile 550 (!) transitive dependencies. A little while later, the build failed, could not compile libc, unicode-xid, cfg-if, proc-macro2. Not sure, maybe I have the wrong version of "cargo" installed?
I get back to my small current hobby project, which is somehow more rewarding to me since I can still check it out on a fresh Linux or Windows box, run "build.sh" and run it. That whole process can complete in 20 seconds.
Am I too stubborn? Or should a terminal emulator really be not such a massive project? (No offense meant).