{"id":15032615,"url":"https://github.com/spa5k/is_sudo","last_synced_at":"2025-04-09T21:23:32.423Z","repository":{"id":54048404,"uuid":"522016572","full_name":"spa5k/is_sudo","owner":"spa5k","description":"Checks whether the process is running as root/sudo/admin permission in Windows and Unix systems","archived":false,"fork":false,"pushed_at":"2022-08-06T18:27:40.000Z","size":6,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-03-21T17:04:17.604Z","etag":null,"topics":["admin","linux","rust","rustlang","sudo","unix","windows"],"latest_commit_sha":null,"homepage":"https://crates.io/crates/is_sudo","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/spa5k.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-08-06T17:52:25.000Z","updated_at":"2024-05-13T13:33:06.000Z","dependencies_parsed_at":"2022-08-13T06:20:13.196Z","dependency_job_id":null,"html_url":"https://github.com/spa5k/is_sudo","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spa5k%2Fis_sudo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spa5k%2Fis_sudo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spa5k%2Fis_sudo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spa5k%2Fis_sudo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/spa5k","download_url":"https://codeload.github.com/spa5k/is_sudo/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248113133,"owners_count":21049788,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["admin","linux","rust","rustlang","sudo","unix","windows"],"created_at":"2024-09-24T20:18:53.649Z","updated_at":"2025-04-09T21:23:32.394Z","avatar_url":"https://github.com/spa5k.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Is_sudo\n\n## Checks if program is running as sudo in unix systems, or using admin permission in windows.\n\n## Usage\n\n```rust\nuse is_sudo::check;\nuse is_sudo::RunningAs;\n\nfn main() {\n    let running_as: RunningAs = is_sudo::check();\n\n    match running_as {\n        RunningAs::Root =\u003e println!(\"Running as root\"),\n        RunningAs::User =\u003e println!(\"Running as user\"),\n    }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspa5k%2Fis_sudo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fspa5k%2Fis_sudo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspa5k%2Fis_sudo/lists"}