Live data from Hacker News

St – A simple terminal implementation for X

st.suckless.org

221–223 of 223 posts

Re: St – A simple terminal implementation for X

#221
post #158

Earlier quoted context omitted.

> Also, one should keep in mind that having to apply personal patches is perfectly acceptable for suckless software. I don't get it. This patch increases the code base by merely 60 lines of code (104 insertions, 44 deletions). Is 60 lines already considered bloat, in a verbose language like C? Also, is this meant to lead to fewer complexity? Maintaining the patch separately from the code base is nothing but cumbersom…

> Is 60 lines already considered bloat, in a verbose language like C? Due to high code quality, removing even 10 lines is an achievement for suckless.org projects. Try it yourself and submit a patch to mailing list if you succeed. > Also, is this meant to lead to fewer complexity? Maintaining the patch separately from the code base is nothing but cumbersome. Maintaining feature as a patch prevents you from weaving it…

> Maintaining feature as a patch prevents you from weaving it deep inside the code, adding hooks here and there just to make it work. It is harder to do, but it is the right way to make sure all feature related logic is kept in one place.

I'm used to achieve this by keeping each topic in a separate module (in C: function or file, in other languages: module, class, whatever). You'd then have clear entry points into that module.

Interestingly, the given patch isn't structured like that. So I'd argue that code would benefit from becoming a first-class citizen in the code base. As a patch it just gives the illusion of a well-separated feature. (Because a patch file is always a single file, no matter how much the changes are scattered around in the code base.)

> I have some pet suckless inspired projects. During development I introduced some useless features such as pthread support just because I learned about them. Then once I realized they are useless I removed them. It greatly improved code structure.

I fully agree that removing useless features does not only shorten, but simplify code. However, given that by far not everybody uses screen/tmux, I disagree with the "scrolling is useless" assumption here.

Re: St – A simple terminal implementation for X

#222

Earlier quoted context omitted.

parserless configuration is easily achieved with stuff like envdir: https://cr.yp.to/daemontools/envdir.html

That just parses environment variables, instead of files.

Not to mention that it's yet another dependency, which is another thing that's avoided by doing configuration through a header file.

Re: St – A simple terminal implementation for X

#223

Earlier quoted context omitted.

Bugs. When you work all day long in a terminal, you need it to be reliable. As I mentioned above, xfce4-terminal is what I normally use but select-to-copy doesn't work 100% of the time. This is super annoying. I'd switch to rxvt but it has its own problems. Despite having had terminals for so much longer, *nix has fallen behind macOS when it comes to terminal usability and reliability.

Termite is pretty good and bug-free in my experience.

Hey, thanks for the tip on Termite. I've been using it since reading your comment and it's awesome. Cut and paste and URL opening both work flawlessly!
Post reply on HN