Merge pull request #121 from pop-os/zombie_jammy

This commit is contained in:
Victoria Brekenfeld 2023-05-25 22:51:53 +02:00 committed by GitHub
commit fb2d6850d9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 30 additions and 22 deletions

View file

@ -18,7 +18,7 @@ endif
VENDOR ?= 0
ifneq ($(VENDOR),0)
ARGS += --locked
ARGS += --offline --locked
endif
TARGET_BIN="$(DESTDIR)$(bindir)/$(BINARY)"

3
debian/rules vendored
View file

@ -15,9 +15,6 @@ ifeq ($(VENDOR),1)
ischroot || make vendor
endif
override_dh_auto_build:
CARGO_HOME="$$(pwd)/target/cargo" make
override_dh_installinit:
dh_installinit -r

2
debian/source/options vendored Normal file
View file

@ -0,0 +1,2 @@
tar-ignore=target
tar-ignore=vendor

View file

@ -1137,24 +1137,33 @@ impl State {
workspace.toggle_floating_window(seat);
}
Action::Spawn(command) => {
if let Err(err) = std::process::Command::new("/bin/sh")
.arg("-c")
.arg(command.clone())
.env("WAYLAND_DISPLAY", &self.common.socket)
.env(
"DISPLAY",
&self
.common
.xwayland_state
.as_ref()
.map(|s| format!(":{}", s.display))
.unwrap_or(String::new()),
)
.env_remove("COSMIC_SESSION_SOCK")
.spawn()
{
warn!(?err, "Failed to spawn \"{}\"", command);
}
let wayland_display = self.common.socket.clone();
let display = self
.common
.xwayland_state
.as_ref()
.map(|s| format!(":{}", s.display))
.unwrap_or_default();
std::thread::spawn(move || {
let mut cmd = std::process::Command::new("/bin/sh");
cmd.arg("-c")
.arg(command.clone())
.env("WAYLAND_DISPLAY", &wayland_display)
.env("DISPLAY", &display)
.env_remove("COSMIC_SESSION_SOCK");
match cmd.spawn() {
Ok(mut child) => {
let _res = child.wait();
}
Err(err) => {
tracing::warn!(?err, "Failed to spawn \"{}\"", command);
}
}
});
}
}
}