Josh 🦀🐪

@joshmo-dev.bsky.social

beep boop beep boop gh https://github.com/joshua-mo-143 me https://joshmo.ooo

Rust constants are slowly but surely getting more powerful! On stable you can parse constants from environment variables. I remember having to pull in weird crates & macros to be able to do this. #rustlang

const TASK_COUNT: usize = {
    let input = if let Some(string) = option_env!("PERFMON_TASK_COUNT") {
        string
    } else {
        "16"
    };
    match usize::from_str_radix(input, 10) {
        Ok(val @ 2..) => val,
        Ok(_) => panic!("PERFMON_TASK_COUNT must be 2 or higher"),
        Err(_e) => panic!("Could not parse `PERFMON_TASK_COUNT`"),
    }
};

I'm leaving the Playgrounds team in a couple weeks (aka, the team that maintains the `rig` family of crates). Pretty happy with everything we've done. If you are eager to see where I'm going, check my GitHub profile. If not, wait a couple of weeks before I do another post I guess

See how Gleam gets the job done in production ⭐ Full case study coming soon: “For a team like ours, with many other priorities and projects we need to work on, the confidence that Gleam gives us is worth its weight in gold.” - Edward Kelly, Director of Technology at Strand.

Graphic with a headline "Gleam in production" and a quote: “Adopting a new language is always a gamble, but Gleam has paid off. The belt-and-braces approach to safety and fault-tolerance has given us a system that just works, reliably, day in and day out, without constant babysitting and maintenance.” - Edward Kelly, Director of Technology at Strand. 
Navy background, blue and green text, pink lucy starfish in bottom right corner

Excited to be releasing rig v0.14 soon! Many new features to come and I'm also working on many more over the next few weeks to make the library (and its experimental counterpart rig-experimental) way better 🙂

😂 Someone called one of my old articles that I wrote "AI-generated garbage". Yes, the article and repo is probably outdated. I don't work for the company I wrote it for anymore. But it's definitely not AI generated.

for my js devs (or devs that are forced to work with js for their day job): are you using js registry? i'm actually curious on what the consensus is now that it's been out and the initial novelty has worn off

I've been inspired to write a Rust library for splitting audio easily. Turns out while writing my Discord call transcription bot (for my DnD group), I've learned the hard way that having a library that can easily split audio is actually kind of a good idea. Maybe something coming soon?

Just gave a talk yesterday on RAG pipelines with Rust and SurrealDB using the framework I maintain at work. Looking forward to when it gets uploaded to YouTube so I can share it with everyone 🥳