yoda: warning cleanup sweep (dead code + clippy --fix) (squashed)
Squash of 4 yoda commits: -84437e21yoda: libcosmic-yoda dead-code purge (14->0 warnings) -999db0a4yoda: cosmic-theme cleanup (4->0 warnings) — workspace at 0 warnings total -4743bb8eyoda: cargo clippy --fix on libcosmic-yoda (115->33 warnings) -675f3b59chore: reduce local stack warnings
This commit is contained in:
parent
c85efc6180
commit
4e1080108c
35 changed files with 173 additions and 210 deletions
|
|
@ -769,7 +769,7 @@ impl DesktopEntryData {
|
|||
pub async fn spawn_desktop_exec<S, I, K, V>(
|
||||
exec: S,
|
||||
env_vars: I,
|
||||
app_id: Option<&str>,
|
||||
_app_id: Option<&str>,
|
||||
terminal: bool,
|
||||
) where
|
||||
S: AsRef<str>,
|
||||
|
|
@ -816,13 +816,17 @@ pub async fn spawn_desktop_exec<S, I, K, V>(
|
|||
// https://systemd.io/DESKTOP_ENVIRONMENTS
|
||||
//
|
||||
// Similar to what Gnome sets, for now.
|
||||
if let Some(pid) = crate::process::spawn(cmd).await {
|
||||
if let Some(_pid) = crate::process::spawn(cmd).await {
|
||||
#[cfg(feature = "desktop-systemd-scope")]
|
||||
if let Ok(session) = zbus::Connection::session().await {
|
||||
if let Ok(systemd_manager) = SystemdMangerProxy::new(&session).await {
|
||||
let _ = systemd_manager
|
||||
.start_transient_unit(
|
||||
&format!("app-cosmic-{}-{}.scope", app_id.unwrap_or(&executable), pid),
|
||||
&format!(
|
||||
"app-cosmic-{}-{}.scope",
|
||||
_app_id.unwrap_or(&executable),
|
||||
_pid
|
||||
),
|
||||
"fail",
|
||||
&[
|
||||
(
|
||||
|
|
@ -833,7 +837,7 @@ pub async fn spawn_desktop_exec<S, I, K, V>(
|
|||
),
|
||||
(
|
||||
"PIDs".to_string(),
|
||||
zbus::zvariant::Value::from(vec![pid])
|
||||
zbus::zvariant::Value::from(vec![_pid])
|
||||
.try_to_owned()
|
||||
.unwrap(),
|
||||
),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue