Skip Navigation

InitialsDiceBearhttps://github.com/dicebear/dicebearhttps://creativecommons.org/publicdomain/zero/1.0/„Initials” (https://github.com/dicebear/dicebear) by „DiceBear”, licensed under „CC0 1.0” (https://creativecommons.org/publicdomain/zero/1.0/)PH
Posts
1
Comments
131
Joined
2 yr. ago

  • Behold, Rust is blazingly fast in approaching the most popular language :)

    Also, in comparison to Python you can do pretty much everything throughout the stack, which would be the reason I would go for Rust (not mentioning all the other niceties it has to offer).

    Also learning Rust nowadays is much more approachable compared to say 7+ years back (ecosystem got way better)

  • Depends on what trait bound error messages you have had yet, I had 1000 lines long already, where it's not obvious at all what is meant (and is often a very simple fix). But I'm sure this will get better over time, there's already a bigger ongoing redesign of the type system solver, so maybe it will be integrated into stable rust soon.

  • Yes

    Jump
  • but effectively it's bash, I think /bin/sh is a symlink to bash on every system I know of...

    Edit: I feel corrected, thanks for the information, all the systems I used, had a symlink to bash. Also it was not intended to recommend using bash functionality when having a shebang !#/bin/sh. As someone other pointed out, recommendation would be #!/usr/bin/env bash, or !#/bin/sh if you know that you're not using bash specific functionality.

  • Yep this sums up my experience quite well too.

    I want to emphasize two things here:

    • Learn reading code (by reading code...) of high quality open source projects. It helps getting new concepts and actual creative coding patterns for concrete problems (unlike learning all these "design patterns" in books that IMHO are often just boilerplate generation (hard take I know...)).
    • Start coding (open source) projects, especially challenging ones, and keep pushing your limits, by trying to learn new smart things, how to achieve problem X. I stagnated in my workplace for quite some time, got unhappy (around COVID), scaled down working hours significantly (I have quite a spartan life, so I can fortunately afford it), and am coding a lot more open source since then. I think I almost learned more in the last 2-3 years until at least to the years of university (quite some time ago), maybe even more than in university, and have a lot more fun while coding. I think going in depth with a programming language comes automatically, when the project is fancy enough, I learned a lot of limitations of Rust (and thus basically reached the deepest level of (parts of) the language) while designing smart APIs.
  • Drew Devault’s Hare language

    Ok, they say "use your distros package-manager", that's basically asking for the same disaster as C or C++. I think cargo is one of the selling points of Rust.

    At least say something like we use "Nix" for default package-management (which does a lot of things right)...

  • I think it's not that bad yet, when comparing with npm. Usually the dependencies I use are of very high quality. But I'm also very selective with dependencies. I'm rather writing a simple part myself, than using a not-really maintained low-quality dependency...

    Btw. I have not looked into the Hare language yet (will do that now), but if it's similar as deno, I won't like it. You want to have some kind of package management IME...

  • Yeah the strict type-system of Rust is great at finding issues.

    I think when understanding, that bash is basically only programs with parameters ([ is a program that takes all kinds of parameters and as last parameter ]) then bash is quite ok for stuff that doesn't need a lot of algorithms, i.e. passing the in and out from one program to another. But as soon as there's basic logic, You'll want to use a fully-fledged programming language.

    Also the maintainability aspect: You can just start using fancy stuff you never want to use in bash and it can slowly grow into a library or application or something like that.

    Btw. I have started a syntax-sugar library/crate that creates typing information for all kinds of programs via the builder-type-state-pattern, so that you don't always have to look up man etc. and that it should be more convenient to execute programs (not open sourced yet, and low priority for me as I'm working on various other exciting projects currently)

  • Yeah as weird as it sounds to use a "low"-level systems programming language such as Rust. Rust works surprisingly well as "script" language. (And you don't have to deal with the ugliness of bash, admittedly though, that bash is quite a bit more concise when using a lot of program executions and piping the results etc.)

  • I'm totally aware of the benefits of encapsulation, but the way java does it seems so unnecessarily boilerplatey (C# is better, functional programming makes encapsulation even simpler, but that's a different paradigm...)

    I like how Rust approaches this via the module system and crates (you have pub for the public interface, pub(crate) for crate/lib wide access and no modifier for being only allowed to access in the current module and submodules of that module)

  • Yeah but why do I have to use an IDE to generate getters and setters in the first place? It just adds up to more mental overhead, because my brain has to process this boilerplate somehow, even if my IDE can generate it (I know it's simple code, but it's even simpler to not have that boilerplate code at all).

  • The curse of OOP (java style...).

    I mean why do you need to write getter and setter methods. I have wondered at the beginning of university 10 years ago, and am still wondering why you would need something like that...

  • Not without a super fancy type system that has to be still found. I think the key issue is cyclic data-structures (e.g. doubly-linked list). The language somehow needs to have strong/weak pointers and automatically determining them is a very complex research question...

  • At this point, I think it's almost mainstream, and it's still growing fast (and it's getting better, rust-analyzer is really awesome these days, I was there at the beginning, no comparison to today...))

    I may be biased, but I think it'll be the next big main language probably leaving other very popular ones behind it in the coming decade (Entry barrier and ease of use got much better over the last couple years, and the future sounds exciting with stuff like this)

  • Nah the old official reddit code is entirely out of date, writing up something like the original official reddit clone, is not too hard, and I would rather rewrite it (in Rust obviously ).

    Hubzilla is certainly an interesting and ambitious project (though a PHP codebase repels me a little bit, TBH). Need to check it out further. Zot also sounds interesting. Looks a little bit like a swiss-army-knife sandbox-toolkit of federated social networks.

  • misunderstanding was

    I think here's a misunderstanding too :). With quickly I mean closing without getting feedback, or without providing a good reason why the issue is closed (without being obviously resolved), not the dates (which I think are only relevant, when actually awaiting a response). I have seen this over the repo a few times, good writeups often explaining some behavior etc. and then bam closed, either as duplicate (although it's not (example)), or "not as planned" etc. I think this is not good behavior for an open source project (I'm around the block for a few years contributing and maintaining OSS, for reference...). Especially as this is a real community project and not some random opinionated application (well depending on how you define it, could be true to lemmy, but I don't think it is...)

    I rather let an issue open than close it, "just to have fewer open issues". I can close it anytime, and if someone searches for that issue sees it closed while it isn't resolved, it just creates confusion...