Skip to content

Commit b4c40f7

Browse files
nrabulinskislp
authored andcommitted
Pass in cwd as part of guest configuration
Signed-off-by: Nikodem Rabuliński <[email protected]>
1 parent d4d0691 commit b4c40f7

2 files changed

Lines changed: 3 additions & 0 deletions

File tree

crates/muvm/src/bin/muvm.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -380,6 +380,7 @@ fn main() -> Result<ExitCode> {
380380

381381
let muvm_guest_path = find_muvm_exec("muvm-guest")?;
382382

383+
let cwd = env::current_dir()?;
383384
let display = env::var("DISPLAY").ok();
384385
let guest_config = GuestConfiguration {
385386
command: Launch {
@@ -395,6 +396,7 @@ fn main() -> Result<ExitCode> {
395396
host_display: display,
396397
merged_rootfs: options.merged_rootfs,
397398
emulator: options.emulator,
399+
cwd,
398400
};
399401
let mut muvm_config_file = NamedTempFile::new()
400402
.context("Failed to create a temporary file to store the muvm guest config")?;

crates/muvm/src/utils/launch.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ pub struct GuestConfiguration {
4343
pub host_display: Option<String>,
4444
pub merged_rootfs: bool,
4545
pub emulator: Option<Emulator>,
46+
pub cwd: PathBuf,
4647
}
4748

4849
pub const PULSE_SOCKET: u32 = 3333;

0 commit comments

Comments
 (0)