Our great sponsors
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
-
sqlx
🧰 The Rust SQL Toolkit. An async, pure Rust SQL crate featuring compile-time checked queries without a DSL. Supports PostgreSQL, MySQL, and SQLite. (by launchbadge)
-
config-rs
⚙️ Layered configuration system for Rust applications (with strong support for 12-factor applications).
-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
-
twelf
Twelf is a configuration solution for Rust including 12-Factor support. It is designed with layers in order to configure different sources and formats to build your configuration. The main goal is to be very simple using a proc macro.
Mystified about strings? Borrow checker have you in a headlock? Seek help here! There are no stupid questions, only docs that haven't been written yet. Please note that if you include code examples to e.g. show a compiler error or surprising result, linking a playground with the code will improve your chances of getting help quickly.
AOC-SPOILER
You might be interested in cargo-make, which is based on TOML, or Just, which has a syntax that is vaguely inspired by Make but much less weird sigils and more suited to non-file-based tasks.
I just read the above article by the official rust blog. I wanted to ask what is "feature" and "badge" refered to as in this blog? what does it mean? At some places "shields.io badge " is mentioned. Are "badge" and "feature" some rust terminologies? It will be helpful if someone explains me this blog post in fewer words.
The only ways to convert float to int right now are using "as", or the unsafe "to_int_unchecked" methods defined for the floating point types. There's an open feature request for "to_int_checked" methods, but it looks like it was posted and only had a couple days of comments without any agreement on what the final semantics would look like: https://github.com/rust-lang/rfcs/issues/3304
Badges are the little rectangles you typically see at the top of a crate's README: https://github.com/launchbadge/sqlx/blob/main/README.md
I like config.rs, but I am struggling to overwrite config profiles with environment variables. The desired config is mixed, like .toml
[profiles.mys3] type = "s3" region = "us-east-1" access_key_id = "foo" enable_virtual_host_style = "on" ``` The team at Opendal wrote a handcrafting config parser for the same use case, see. Since parsing configs in toml or json is a standard functionality, is there any recommended way?
Thank you, I thought about this one. The challenge with config.rs it doesn't support lists and hashes in environment variables. I found a crate which does exactly what I need Twelf - surprisingly unpopular.