Don't set the DISPLAY env var

This is the only case where init sets an env var without the user
instructing it to do so, making it hard to trace back where the env var
originated from. It also only sets it for processes spawned after the
first run.d command for whatever reason. And finally not setting DISPLAY
avoids hard coding knowledge about unrelated system components.
This commit is contained in:
bjorn3
2024-07-20 16:45:41 +02:00
parent ec04d52c7e
commit 050febc94f
-1
View File
@@ -127,7 +127,6 @@ pub fn run(file: &Path) -> Result<()> {
if missing_arg {
println!("init: failed to run.d: no argument or all dirs are non-existent");
} else {
std::env::set_var("DISPLAY", "3");
// This takes advantage of BTreeMap iterating in sorted order.
for (_, entry_path) in entries {
if let Err(err) = run(&entry_path) {