Crates.io | runas |
lib.rs | runas |
version | 1.2.0 |
source | src |
created_at | 2016-06-15 19:08:45.453434 |
updated_at | 2024-02-20 12:15:12.190882 |
description | Run a command as root (sudo) |
homepage | https://github.com/mitsuhiko/rust-runas |
repository | |
max_upload_size | |
id | 5388 |
size | 31,759 |
A simple Rust library that can execute commands as root.
use runas::Command;
let status = Command::new("rm")
.arg("/usr/local/my-app")
.status()
.unwrap();