1 2 3 4 5 6 7 8 9 10 11 12 13
use std::process::Command; use super::EditorOpen; pub struct VSCode; impl EditorOpen for VSCode { fn open(&self, dir: &str) -> Result<(), ()> { // TODO: inte använt let _command = Command::new("code").args([dir]).spawn().unwrap().wait(); Ok(()) } }