๐ŸŽ‰ first #Rust crate published! (for RealtimeKit)

https://crates.io/crates/rtkit-rs

Most of the work was @sanchayan, with a h/t to @zeenix for all the D-Bus heavy-lifting in #zbus.

#rustlang

crates.io: Rust Package Registry

Yay, I just published a new opensource project! It is a small program I wrote to solve an inconvenience I experienced with my computer use:

Mounting & unmounting removable devices from command line (on Linux).

Whatever DE I use, I tend to work mostly with the keyboard. So I wanted a short command that would do this for me with as little typing and interaction as possible.

That includes mounting / unmounting at the right place, unlocking / locking encrypted volumes, as well as doing anything necessary to safely remove the device (powering off when supported, locking encrypted volumes after unmount, unmounting other partitions on the same device if present, etc).

It uses UDisks as its backend (but multiple backends can be implemented if desired).

Before I wrote this tool, I was using `bashmount`, which provided inspiration, but I wanted something a bit more ergonomic for my day to day use.

Some of you may have voted in a poll I did a long time ago for choosing its name๐Ÿ˜‰

Hence:

https://codeberg.org/undltd/om

I decided to release it early, as soon as I started using it myself and felt it does the job. If circumstances permit, I'll be able to add niceties and further smooth out the UX, maybe even add features (see the Roadmap for ideas I have at the moment), but I hope it won't become "big and professional" ๐Ÿ˜‰ Maybe I can port it to *BSD at some point๐Ÿค”

Also, this is my first "real" program in Rust.

Enjoy!

(P.S. This program was written during and despite russian war.)

#Rust #Linux #UDisks #DBus #zbus

om

A command line tool to conveniently mount, unmount, (un)lock and safely power off storage devices on Linux with as few keystrokes as possible.

Codeberg.org

Mngh. I'm banging my head into a thick brick wall again, it seems.

I'm trying to use #zbus (a #rust crate to communicate with dbus). I have a function that returns HashMap<String, HashMap<String, zvariant::OwnedValue>>. So far, so good!

I can pick out the connection key fine. From that, I want to pick out ssid, which is an array of bytes, and then convert that to an utf8 string. Now that part is giving me a headache, because I have no idea how to go from zvariant::OwnedValue to either Vec<u8>, or String.

When it's Friday evening but you're really in the zone and have many great ideas on how to finally come out of the rabbit hole you've gotten yourself deep into for weeks in a row

#zbus #refactoring #rustlang

About two weeks and ~400 submitted #Fedora updates later, another #Rust on #Fedora update:

1. I updated the #zbus crates to the latest version after two new dependencies finally made it through package review. And a few hours later, upstream released new versions of all six zbus subprojects ๐Ÿคช

I made a console app to work-around easy-to-miss notifications on the MS Teams PWA for Linux.

I learned quite a bit about dbus and freedesktop notifications spec, so that was fun ๐Ÿ˜ƒ

Check it out at https://github.com/christianfosli/msteams-notify-with-sound

#msteams #pwa #linux #dbus #zbus

GitHub - christianfosli/msteams-notify-with-sound

Contribute to christianfosli/msteams-notify-with-sound development by creating an account on GitHub.

GitHub
Am I doing it wrong or is dbus_interface in #zbus basically forcing me to leak references?
Tried structs with lifetimes but it seems like dbus_interface always forces the struct field lifetime to 'static.

while the number of people on #zbus matrix channel vary slightly, I've noticed that on average there are 42 people there. It's been around this number for 1-2 years now.

#MeaningOfLife

only way to find out all the implicit assumptions in your D-Bus library about the bus behavior: you write your own bus.

#dbus #zbus.

If you see a new Mercedes-Benz eVito van? It has @zbus on it. ๐Ÿ˜Ž Yes, my crate is enabling the delivery of your crates ๐Ÿ˜‰

#mercedesbenz #zbus #rustlang