mirror of
https://github.com/nushell/nushell.git
synced 2025-07-18 07:04:48 +02:00
1.88.0 was released today, clippy now lints (machine-applicable) against: - format strings with empty braces that could be inlined - easy win - `manual_abs_diff` - returning of a stored result of the last expression. - this can be somewhat contentious but touched only a few places
22 lines
705 B
Rust
22 lines
705 B
Rust
use nu_plugin::{MsgPackSerializer, serve_plugin};
|
|
use nu_plugin_polars::PolarsPlugin;
|
|
|
|
fn main() {
|
|
env_logger::init();
|
|
|
|
// Set config options via environment variable
|
|
unsafe {
|
|
// Extensions are required for certain things like aggregates with object dtypes to work
|
|
// correctly. It is disabled by default because of unsafe code.
|
|
// See https://docs.rs/polars/latest/polars/#user-guide for details
|
|
std::env::set_var("POLARS_ALLOW_EXTENSION", "true");
|
|
}
|
|
match PolarsPlugin::new() {
|
|
Ok(ref plugin) => serve_plugin(plugin, MsgPackSerializer {}),
|
|
Err(e) => {
|
|
eprintln!("{e}");
|
|
std::process::exit(1);
|
|
}
|
|
}
|
|
}
|