Skip to content

Commit

Permalink
Default to using x11bridge instead of sommelier
Browse files Browse the repository at this point in the history
Replace "direct_x11" with "sommelier" in muvm command line arguments and
default to using x11bridge unless the latter is present.

Signed-off-by: Sergio Lopez <[email protected]>
  • Loading branch information
slp authored and asahilina committed Dec 4, 2024
1 parent d937acb commit b40bf03
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion crates/muvm/src/bin/muvm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ fn main() -> Result<()> {
);
env.insert("MUVM_SERVER_COOKIE".to_owned(), cookie.to_string());

if options.direct_x11 {
if !options.sommelier {
let display =
env::var("DISPLAY").context("X11 forwarding requested but DISPLAY is unset")?;
env.insert("HOST_DISPLAY".to_string(), display);
Expand Down
9 changes: 4 additions & 5 deletions crates/muvm/src/cli_options.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ pub struct Options {
pub root_server_port: u32,
pub server_port: u32,
pub fex_images: Vec<String>,
pub direct_x11: bool,
pub sommelier: bool,
pub interactive: bool,
pub command: PathBuf,
pub command_args: Vec<String>,
Expand Down Expand Up @@ -105,9 +105,8 @@ pub fn options() -> OptionParser<Options> {
.argument("SERVER_PORT")
.fallback(3334)
.display_fallback();
let direct_x11 = long("direct-x11")
.short('x')
.help("Use direct X11 forwarding instead of sommelier + XWayland")
let sommelier = long("sommelier")
.help("Use sommelier + XWayland instead of x11bridge")
.switch();
let interactive = long("interactive")
.short('i')
Expand All @@ -129,7 +128,7 @@ pub fn options() -> OptionParser<Options> {
root_server_port,
server_port,
fex_images,
direct_x11,
sommelier,
interactive,
// positionals
command,
Expand Down

0 comments on commit b40bf03

Please sign in to comment.