How can I contribute with Rust to Garuda?

I'm junior in the software field and Rust is my favorite language. I want to become better at it and also build my portfolio on GitHub so that I can show recruiters that I've contributed to open-source projects in Rust so I can get a job in Rust. It would be especially interesting if the project I'm working on somehow creates value in my everyday digital life, so I thought Garuda may be a good place to make a contribution to since I'm using it myself.

Do you have any programming/engineering tasks that would be valuable to write in Rust? I would love to learn about it so I can contribute

To my knowledge Garuda doesn't have any applications written in rust.

4 Likes

Might be a good idea to try rewrite some of the programs in rust if this guy has knowledge in that area. I hear good things about it in terms of performance and maintainability so would be interesting to rewrite a program and test it locally against the original implementation and benchmark it or something to see how rust may affect current tools. And depending on how they perform maybe consider a pull request with the rust code? Anyway with rust, afaik, it is good to implement but the whole program likely doesn’t need to be all rust. Maybe consider implementing it in areas that involve loading and hooks into other services. I’d be interested to see how rust may impact load times among other things. There’s gotta be a reason it’s so popular lately with everyone seemingly using it and Linus wanting it implemented into the Linux kernel right?

1 Like

If you exclude the shell scripts, the Garuda applications are mostly written in C++.

Randomly rewriting things in Rust because it is popular seems like a relatively poor strategy. Given the nature of the applications that Garuda maintains, any real world performance gains should be minimal between C++ and Rust. Any gains achieved would more likely be related to more/less efficient coding approaches as opposed to the languages themselves.

It would make much more sense to write new applications in Rust assuming the team as a whole wanted to learn and work in Rust. Since this is a volunteer project, it is much more important that the applications are written in something the team enjoys working in as opposed to using whatever language is the flavor of the month.

13 Likes

It’s not about the popularity though. The key selling point with Rust is that it has the same performance as C++, and similar syntax, but you eliminate the issue of memory leaks to improve cybersecurity and reduce risk of bugs/errors in runtime by moving them to compile time where it can be solved before causing problem to live users.

2 Likes

To be clear, my response was to the poster directly above me who suggested we should rewrite our existing applications in Rust. I find that exercise to be wasteful given the nature of the applications that Garuda develops.

I have nothing against Rust generally.

Almost every language has advantages over other languages. If there was one perfect language, everyone would be using it universally.

4 Likes

You assume people pick languages based on completely objective merits.

Particularly when it comes to memory leaks and security related issues, and also expressiveness and availability of higher level abstractions due to functional oriented language designs, is Rust objectively more suitable for basically any task, other than for existing projects..

Nim could do that, and most of what Rust does on top with a saner syntax, but this is a different topic

But people don't decide logically, they decide based on job opportunity, the force of habit and subjective interpretation of perceived benefits :smiley:

Nothing wrong with C++ (well, a lot, but .. still everyone's free choice) but programming languages are rarely used based on the technical aspects.

2 Likes

A good ol' code fight!

I can't wait until they start slapping each other with "Hello Worlds."
:boxing_glove: :rofl:

6 Likes
printfn "Hello from F#" 

:smiley:

I believe there is a bug in /usr/bin/rate-mirrors which occasionally causes it to write an empty file - at least that's what the comments in /usr/lib/garuda/garuda-update/main-update state. I've not looked for a bug report to verify this.

/usr/bin/rate-mirrors appears to be written in rust or uses rust code internally.

I guess finding and correcting that bug would be an interesting exercise for you to add to your portfolio.

4 Likes

Actually that's a pretty good idea :eyes: add support for rating chaotic-aur mirrors to rate-mirrors :slight_smile:

5 Likes

thanks for the suggestion! I'm pretty novice on Rust at the moment so I need to first do some research in the docs to figure out how the Rust language works, and I'll keep this suggestion on my to-do list for the future

Read “the book” - it’s very good; I guess you’re already doing this but I also recommend trying some of the exercises on the rust track of exercism.. They start fairly easily, they are graded in difficulty, it’s mentored should you get stuck or want advice and it’s entirely free which is always a bonus! :slight_smile:

Enjoy your rust coding - it’s a nice language.

1 Like
curl https://mirrorlist.chaotic.cx/rate-mirrors | rate-mirrors --allow-root --per-mirror-timeout=3000 stdin --path-to-test="no-failover/chaotic-aur/x86_64/chaotic-aur.files?chaotic-no-db-redir" --path-to-return='no-failover/$repo/$arch' --comment-prefix="# "
2 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.