Skip to content

Commit

Permalink
Lutris 0.5.13 fixed version detection
Browse files Browse the repository at this point in the history
  • Loading branch information
the-sane committed May 24, 2023
1 parent 1c9f242 commit 66775c6
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions lug-helper.sh
Original file line number Diff line number Diff line change
Expand Up @@ -857,16 +857,12 @@ lutris_check() {
return 1
fi

# TODO: This was reported and fixed. Verify and remove when v0.5.13 is released
if [ "$(pgrep -f lutris)" ]; then
preflight_fail+=("Unable to detect Lutris version info while it is running.\nVersion $lutris_required or newer is required.")
return 1
fi

# Check the native lutris version number
if [ "$lutris_native" = "true" ]; then
lutris_current="$(lutris -v | awk -F '-' '{print $2}')"
if [ "$lutris_required" != "$lutris_current" ] &&
if [ -z "$lutris_current" ]; then
preflight_fail+=("Unable to detect Lutris version info.\nVersion $lutris_required or newer is required.")
elif [ "$lutris_required" != "$lutris_current" ] &&
[ "$lutris_current" = "$(printf "%s\n%s" "$lutris_current" "$lutris_required" | sort -V | head -n1)" ]; then
preflight_fail+=("Lutris is out of date.\nVersion $lutris_required or newer is required.")
else
Expand All @@ -877,7 +873,9 @@ lutris_check() {
# Check the flatpak lutris version number
if [ "$lutris_flatpak" = "true" ]; then
lutris_current="$(flatpak run net.lutris.Lutris -v | awk -F '-' '{print $2}')"
if [ "$lutris_required" != "$lutris_current" ] &&
if [ -z "$lutris_current" ]; then
preflight_fail+=("Unable to detect Flatpak Lutris version info.\nVersion $lutris_required or newer is required.")
elif [ "$lutris_required" != "$lutris_current" ] &&
[ "$lutris_current" = "$(printf "%s\n%s" "$lutris_current" "$lutris_required" | sort -V | head -n1)" ]; then
preflight_fail+=("Flatpak Lutris is out of date.\nVersion $lutris_required or newer is required.")
else
Expand Down

0 comments on commit 66775c6

Please sign in to comment.