Documentation
  • Coverage
  • 0%
    0 out of 2 items documented0 out of 1 items with examples
  • Size
  • Source code size: 10.84 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.09 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 15s Average build duration of successful builds.
  • all releases: 12s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • ahaoboy/is-admin
    0 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • ahaoboy

Check if the current user is admin, use powershell on windows and libc::getuid/libc::geteuid on unix

fn main() {
    println!("is_admin: {}", is_admin::is_admin())
}