8 Commits
v1.8 ... v1.9.1

Author SHA1 Message Date
675621c4c3 solving trying to download the .sha512sum as archive 2021-07-28 11:08:28 +02:00
c07e673c0d ignoring .sha512sum files in runner release pages 2021-07-27 20:32:07 +02:00
b85df29d6d Revert "ignoring .sha512sum files in runner release pages"
This reverts commit 7f3d84a8bc.
2021-07-27 20:31:02 +02:00
7f3d84a8bc ignoring .sha512sum files in runner release pages 2021-07-27 20:29:02 +02:00
6533cf98bd Merge pull request #20 from Wrzlprnft/patch-1
fix locale causing memory preflight check to fail
2021-07-20 08:49:37 +02:00
c7c8cd1ecd fix locale causing memory preflight check to fail
if the locale uses a decimal `,` instead of `.`, the memory preflight check fails
fix provided by @gort818
2021-07-19 16:01:38 +02:00
e0d149494d added script version check and glibc version check for /dev/null 2021-06-15 15:34:40 +02:00
9800420d73 added GloriousEggrolls lutris-Builds - thanks to Eutyches 2021-06-08 17:09:25 +02:00

View File

@ -106,6 +106,8 @@ runners_dir="$data_dir/lutris/runners/wine"
runner_sources=(
"RawFox" "https://api.github.com/repos/rawfoxDE/raw-wine/releases"
"Molotov/Snatella" "https://api.github.com/repos/snatella/wine-runner-sc/releases"
"/dev/null" "https://api.github.com/repos/gort818/wine-sc-lug/releases"
"GloriousEggroll" "https://api.github.com/repos/GloriousEggroll/wine-ge-custom/releases"
)
# Set a maximum number of runner versions to display from each url
max_runners=20
@ -663,7 +665,7 @@ filelimit_check() {
# Check total system memory
memory_check() {
memtotal="$(awk '/MemTotal/ {printf "%.1f \n", $2/1024/1024}' /proc/meminfo)"
memtotal="$(LC_NUMERIC=C awk '/MemTotal/ {printf "%.1f \n", $2/1024/1024}' /proc/meminfo)"
if [ ${memtotal%.*} -ge "15" ]; then
preflight_pass+=("Your system has $memtotal GB of memory.")
else
@ -819,6 +821,12 @@ runner_install() {
*.tgz)
runner_name="$(basename "$runner_file" .tgz)"
;;
*.tar.xz)
runner_name="$(basename "$runner_file" .tar.xz)"
;;
*.sha512sum)
runner_name="$(basename "$runner_file" .tar.xz)"
;;
*)
debug_print exit "Unknown archive filetype in runner_install function. Aborting."
;;
@ -829,6 +837,7 @@ runner_install() {
# runner_select_install function below
if [ "$runner_url_type" = "github" ]; then
runner_dl_url="$(curl -s "$contributor_url" | grep "browser_download_url.*$runner_file" | cut -d \" -f4)"
debug_print continue "runner_dl_url= $runner_dl_url"
else
debug_print exit "Script error: Unknown api/url format in runner_sources array. Aborting."
fi
@ -882,10 +891,10 @@ runner_install() {
debug_print continue "Installing runner into $runners_dir/$runner_name..."
if [ "$use_zenity" -eq 1 ]; then
# Use Zenity progress bar
mkdir -p "$runners_dir/$runner_name" && tar -xzf "$tmp_dir/$runner_file" -C "$runners_dir/$runner_name" | \
mkdir -p "$runners_dir/$runner_name" && tar -xf "$tmp_dir/$runner_file" -C "$runners_dir/$runner_name" | \
zenity --progress --pulsate --no-cancel --auto-close --title="Star Citizen LUG Helper" --text="Installing runner...\n" 2>/dev/null
else
mkdir -p "$runners_dir/$runner_name" && tar -xzf "$tmp_dir/$runner_file" -C "$runners_dir/$runner_name"
mkdir -p "$runners_dir/$runner_name" && tar -xf "$tmp_dir/$runner_file" -C "$runners_dir/$runner_name"
fi
lutris_needs_restart="true"
;;
@ -894,10 +903,10 @@ runner_install() {
debug_print continue "Installing runner into $runners_dir..."
if [ "$use_zenity" -eq 1 ]; then
# Use Zenity progress bar
mkdir -p "$runners_dir" && tar -xzf "$tmp_dir/$runner_file" -C "$runners_dir" | \
mkdir -p "$runners_dir" && tar -xf "$tmp_dir/$runner_file" -C "$runners_dir" | \
zenity --progress --pulsate --no-cancel --auto-close --title="Star Citizen LUG Helper" --text="Installing runner...\n" 2>/dev/null
else
mkdir -p "$runners_dir" && tar -xzf "$tmp_dir/$runner_file" -C "$runners_dir"
mkdir -p "$runners_dir" && tar -xf "$tmp_dir/$runner_file" -C "$runners_dir"
fi
lutris_needs_restart="true"
;;
@ -931,6 +940,18 @@ runner_select_install() {
;;
esac
# Check for GlibC-Version if TKG is selected, as he requires 2.33
if [ "$contributor_url" = "https://api.github.com/repos/gort818/wine-sc-lug/releases" ]; then
printf "checking for glibc \n"
system_glibc=($(ldd --version | awk '/ldd/{print $NF}'))
printf "system glibc-versuib: $system_glibc \n"
required_glibc="2.33"
if [ "$(bc <<< "$required_glibc>$system_glibc")" == "1" ]; then
message warning "Your glibc version is too low, /dev/null requires v$required_glibc "
proton_manage
fi
fi
# Fetch a list of runner versions from the selected contributor
# To add new sources, handle them here, in the if statement
# just above, and the runner_install function above
@ -967,13 +988,18 @@ runner_select_install() {
*.tgz)
runner_name="$(basename "${runner_versions[i]}" .tgz)"
;;
*.tar.xz)
runner_name="$(basename "${runner_versions[i]}" .tar.xz)"
;;
*)
debug_print exit "Unknown archive filetype in runner_select_install function. Aborting."
runner_name="skip"
;;
esac
# Add the runner names to the menu
if [ -d "$runners_dir/$runner_name" ]; then
if [ "$runner_name" = "skip" ]; then
continue
elif [ -d "$runners_dir/$runner_name" ]; then
menu_options+=("$runner_name [installed]")
else
menu_options+=("$runner_name")
@ -1235,6 +1261,24 @@ fi
live_or_ptu="$live_dir"
lutris_needs_restart="false"
# Credits for this go to https://gist.github.com/lukechilds/a83e1d7127b78fef38c2914c4ececc3c
get_latest_release() {
curl --silent "https://api.github.com/repos/$1/releases/latest" | # Get latest release from GitHub api
grep '"tag_name":' | # Get tag line
sed -E 's/.*"([^"]+)".*/\1/' # Pluck JSON value
}
# Check if a new Verison of the script is available
repo="the-sane/lug-helper"
current_version="v1.9.1"
latest_version=$(get_latest_release "$repo")
if [ "$latest_version" != "$current_version" ]; then
# Print to stdout and also try warning the user through message
printf "New version available, check https://github.com/the-sane/lug-helper/releases \n"
message info "New version available, check <a href='https://github.com/the-sane/lug-helper/releases'>https://github.com/the-sane/lug-helper/releases</a> \n"
fi
# If invoked with command line arguments, process them and exit
if [ "$#" -gt 0 ]; then
while [ "$#" -gt 0 ]