Skip to content

Instantly share code, notes, and snippets.

View virtualritz's full-sized avatar
Rustacean – backend/desktop apps/2D & 3D graphics

Moritz Mœller virtualritz

Rustacean – backend/desktop apps/2D & 3D graphics
View GitHub Profile
virtualritz /
Last active April 19, 2022 12:12
Find the next Friday from today in Rust
use chrono::{offset::Utc, Datelike, Duration}; // 0.4.19
fn main() {
let today_naive = Utc::today()
let num_days_from_monday = today_naive.weekday().num_days_from_monday();
virtualritz /
Last active April 22, 2022 17:38
Making Rust FFI Wrapper Crates Build on


Check for env::var("DOCS_RS") in your and omit linking if it is set.

Where to find this: read the complete About section on

Long Version

If you’ve written wrapper crates, e.g. using bindgen, you may have ran into this. You have:


Keybase proof

I hereby claim:

  • I am virtualritz on github.
  • I am theritz ( on keybase.
  • I have a public key ASDOHUrdRjyKEwcX0YtXMaTFqdxlRHLCCJbSGmtN9er_-Ao

To claim this, I am signing this object: