///| chandra-polkit-agent: Chandra's polkit authentication agent. The compositor starts it on a /// socket pair (its stdin and stdout) and draws the dialog it asks for; see /// compositor/polkit/agent_loop.mbt and docs/auth-dialog.md. It logs to stderr (the session log). /// /// chandra-polkit-agent be this session's polkit agent /// chandra-polkit-agent --demo MODE one pretend request (chandra-ctl auth-demo), then exit ///| fn main { let args = @env.args() let i = args.search("--demo") let agent = match i { Some(k) => @polkit.AgentLoop::new_demo(0, args.get(k + 1).unwrap_or("password")) None => @polkit.AgentLoop::new(0, @polkit.PolkitAgent::new()) } agent.run() }