rust-script,可以在没有任何设置或编译步骤的情况下运行 rust 文件和表达式
$ echo 'println!("Hello, World!");' > hello.rs
$ rust-script hello.rs
Hello, World!
也支持依赖 crate
#!/usr/bin/env rust-script
//! This is a regular crate doc comment, but it also contains a partial
//! Cargo manifest. Note the use of a *fenced* code block, and the
//! `cargo` "language".
//!
//! ```cargo
//! [dependencies]
//! time = "0.1.25"
//!
fn main() {
println!("{}", time::now().rfc822z());
}
$ rust-script now
Wed, 28 Oct 2020 00:38:45 +0100
链接:https://rust-script.org/
GitHub:https://github.com/fornwall/rust-script
quickwit - 又一个基于 tantivy 的新 Rust 搜索引擎
quickwit 刚发布 0.1 版,他号称是一个高性价比的分布式搜索引擎,想让你花尽可能低的成本搜索大量数据。
链接:https://quickwit.io/blog/quickwit-first-release
Github:https://github.com/quickwit-inc/quickwit
Rust 重写 go 项目的一次实践
国外一个工程师用 Rust 重写 go 项目,最开始慢 4~5 倍,然后经过 Rust 社区网友支招优化以后,反过来比 go 项目快且稳定。
这个帖子下涉及一些异步优化技巧可以看看
链接:https://www.reddit.com/r/rust/comments/oje3w7/rewrote_golang_project_in_rust_its_4x_times/
--
From 日报小组 Folyd,侯盛鑫
社区学习交流平台订阅:
Rustcc论坛: 支持rss
微信公众号:Rust语言中文社区