fix: now reloads after swtich
This commit is contained in:
		
							parent
							
								
									ad46eae8b3
								
							
						
					
					
						commit
						8ef9440b83
					
				@ -2,6 +2,7 @@ extern crate clap;
 | 
			
		||||
extern crate rouille;
 | 
			
		||||
 | 
			
		||||
use std::{
 | 
			
		||||
    any::Any,
 | 
			
		||||
    fs,
 | 
			
		||||
    path::Path,
 | 
			
		||||
    sync::{Arc, Mutex},
 | 
			
		||||
@ -40,6 +41,13 @@ fn switch_to_config(base_path: &String, p: String) -> Result<()> {
 | 
			
		||||
        return Err(anyhow!("Something went very wrong"));
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    let res2 = std::process::Command::new("hyprctl").arg("reload").spawn();
 | 
			
		||||
 | 
			
		||||
    if res2.is_err() {
 | 
			
		||||
        println!("Was able to change the link but could not reload hyprland");
 | 
			
		||||
        return Err(anyhow!("Something went very wrong"));
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    return Ok(());
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user