From ed9e92fc2e46fb3272cb4d694802ac8915a45ba7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bojan=20Nem=C4=8Di=C4=87?= Date: Fri, 9 Dec 2022 09:19:44 +0100 Subject: [PATCH] Enable reading ID from CLI --- src/core_main.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/core_main.rs b/src/core_main.rs index d0ce9e0d1..bf6ef7aac 100644 --- a/src/core_main.rs +++ b/src/core_main.rs @@ -221,6 +221,13 @@ pub fn core_main() -> Option> { } } return None; + } else if args[0] == "--id" { + if crate::platform::is_root() { + println!("{}", crate::ipc::get_id()); + } else { + println!("Permission denied!"); + } + return None; } else if args[0] == "--check-hwcodec-config" { #[cfg(feature = "hwcodec")] scrap::hwcodec::check_config();