Clickable wiki URL what an idea

This commit is contained in:
the Sane 2022-01-07 15:55:56 -05:00 committed by GitHub
parent b4762d4724
commit 4b32177e97
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1445,11 +1445,6 @@ install_game() {
# Display the LUG Wiki
display_wiki() {
if [ -x "$(command -v xdg-open)" ]; then
# Open the link in the default browser if xdg-open is available
xdg-open "$lug_wiki" >/dev/null 2>&1
fi
# Display a message containing the URL
message info "See the Wiki for our Quick-Start Guide, Manual Installation instructions,\nPerformance Tuning, and Common Issues and Solutions:\n\n$lug_wiki"
}
@ -1603,21 +1598,6 @@ fi
# Set defaults
live_or_ptu="$live_dir"
# Check if a newer verison of the script is available
latest_version="$(get_latest_release "$repo")"
# Sort the versions and check if the installed Helper is smaller
if [ "$latest_version" != "$current_version" ] &&
[ "$current_version" = "$(printf "$current_version\n$latest_version" | sort -V | head -n1)" ]; then
if [ "$use_zenity" -eq 1 ]; then
releases_url_formatted="<a href='$releases_url'>$releases_url</a>"
else
releases_url_formatted="$releases_url"
fi
message info "The latest version of the LUG Helper is $latest_version\nYou are using $current_version\n\nYou can download new releases here:\n$releases_url_formatted"
fi
# If invoked with command line arguments, process them and exit
if [ "$#" -gt 0 ]; then
while [ "$#" -gt 0 ]
@ -1716,6 +1696,22 @@ Usage: lug-helper <options>
fi
fi
# Format some URLs for Zenity
if [ "$use_zenity" -eq 1 ]; then
releases_url="<a href='$releases_url'>$releases_url</a>"
lug_wiki="<a href='$lug_wiki'>$lug_wiki</a>"
fi
# Check if a newer verison of the script is available
latest_version="$(get_latest_release "$repo")"
# Sort the versions and check if the installed Helper is smaller
if [ "$latest_version" != "$current_version" ] &&
[ "$current_version" = "$(printf "$current_version\n$latest_version" | sort -V | head -n1)" ]; then
message info "The latest version of the LUG Helper is $latest_version\nYou are using $current_version\n\nYou can download new releases here:\n$releases_url"
fi
# Loop the main menu until the user selects quit
while true; do
# Configure the menu