Skip to content

Commit

Permalink
fix: Always launch prompt in a new window when xdg-terminal-exec is c…
Browse files Browse the repository at this point in the history
…alled with no input
  • Loading branch information
KyleGospo committed Dec 22, 2023
1 parent 486fd46 commit d8cc1eb
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions system_files/desktop/silverblue/usr/bin/xdg-terminal-exec
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
#!/usr/bin/env bash

if command -v /usr/bin/prompt > /dev/null; then
/usr/bin/prompt -- "$@"
if test -z "$@"; then
/usr/bin/prompt --new-window
else
/usr/bin/prompt -- "$@"
fi
elif grep '^org\.gnome\.Prompt$' <<< $(/usr/bin/flatpak list --app --columns=application); then
/usr/bin/flatpak run org.gnome.Prompt -- "$@"
if test -z "$@"; then
/usr/bin/flatpak run org.gnome.Prompt --new-window
else
/usr/bin/flatpak run org.gnome.Prompt -- "$@"
fi
else
/usr/bin/gnome-terminal -- "$@"
fi

0 comments on commit d8cc1eb

Please sign in to comment.