diff --git a/Cargo.lock b/Cargo.lock index 7bf4abf..4eb4415 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1630,7 +1630,7 @@ dependencies = [ [[package]] name = "xplr" -version = "0.5.7" +version = "0.5.8" dependencies = [ "anyhow", "chrono", diff --git a/Cargo.toml b/Cargo.toml index 37214c6..3f1fa74 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "xplr" -version = "0.5.7" # Update config.yml, config.rs and default.nix +version = "0.5.8" # Update config.yml, config.rs and default.nix authors = ["Arijit Basu "] edition = "2018" description = "A hackable, minimal, fast TUI file explorer" diff --git a/src/config.rs b/src/config.rs index 1273a72..e854536 100644 --- a/src/config.rs +++ b/src/config.rs @@ -1020,6 +1020,7 @@ impl Config { pub fn is_compatible(&self) -> Result { let result = match self.parsed_version()? { + (0, 5, 8) => true, (0, 5, 7) => true, (0, 5, 6) => true, (0, 5, 5) => true, @@ -1036,7 +1037,8 @@ impl Config { pub fn upgrade_notification(&self) -> Result> { let result = match self.parsed_version()? { - (0, 5, 7) => None, + (0, 5, 8) => None, + (0, 5, 7) => Some("App version updated. Fixed distorted screen when opening files in GUI"), (0, 5, 6) => Some("App version updated. Fixed piping and in-built terminal support"), (0, 5, 5) => Some("App version updated. Significant reduction in CPU usage"), (0, 5, 4) => Some("App version updated. Significant reduction in CPU usage"), diff --git a/src/config.yml b/src/config.yml index b82c292..d779cc0 100644 --- a/src/config.yml +++ b/src/config.yml @@ -1,4 +1,4 @@ -version: v0.5.7 +version: v0.5.8 general: show_hidden: false read_only: false @@ -926,9 +926,20 @@ modes: help: open in gui messages: - BashExecSilently: | - OPENER="$(which xdg-open)" - ${OPENER:-open} "${XPLR_FOCUS_PATH:?}" &> /dev/null + if [ -z "$OPENER" ]; then + if command -v xdg-open; then + OPENER=xdg-open + elif command -v open; then + OPENER=open + else + echo 'LogError: $OPENER not found' >> "${XPLR_PIPE_MSG_IN:?}" + exit 1 + fi + fi + $OPENER "${XPLR_FOCUS_PATH:?}" &> /dev/null & - SwitchMode: default + - ClearScreen + - Refresh on_alphabet: null on_number: null