mirror of
https://github.com/aclist/dztui.git
synced 2024-12-29 13:52:03 +01:00
Check python explicitly
This commit is contained in:
parent
5824f971bb
commit
09cb67134b
2 changed files with 14 additions and 2 deletions
|
@ -5,6 +5,10 @@
|
||||||
- Custom query API
|
- Custom query API
|
||||||
- Standardize dialogs
|
- Standardize dialogs
|
||||||
|
|
||||||
|
## [3.1.0-rc.17] 2022-11-28
|
||||||
|
### Changed
|
||||||
|
- Explicitly check Python version
|
||||||
|
|
||||||
## [3.1.0-rc.16] 2022-11-25
|
## [3.1.0-rc.16] 2022-11-25
|
||||||
### Fixed
|
### Fixed
|
||||||
- Hotfix for server modlists returning multiples of same mod
|
- Hotfix for server modlists returning multiples of same mod
|
||||||
|
|
12
dzgui.sh
12
dzgui.sh
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
version=3.1.0-rc.16
|
version=3.1.0-rc.17
|
||||||
|
|
||||||
aid=221100
|
aid=221100
|
||||||
game="dayz"
|
game="dayz"
|
||||||
|
@ -68,7 +68,7 @@ print_news(){
|
||||||
}
|
}
|
||||||
|
|
||||||
declare -A deps
|
declare -A deps
|
||||||
deps=([awk]="5.1.1" [curl]="7.80.0" [jq]="1.6" [tr]="9.0" [zenity]="3.42.1" [steam]="1.0.0" [python]="3.0")
|
deps=([awk]="5.1.1" [curl]="7.80.0" [jq]="1.6" [tr]="9.0" [zenity]="3.42.1" [steam]="1.0.0")
|
||||||
changelog(){
|
changelog(){
|
||||||
if [[ $branch == "stable" ]]; then
|
if [[ $branch == "stable" ]]; then
|
||||||
md="https://raw.githubusercontent.com/aclist/dztui/dzgui/changelog.md"
|
md="https://raw.githubusercontent.com/aclist/dztui/dzgui/changelog.md"
|
||||||
|
@ -248,6 +248,7 @@ file_picker(){
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
create_config(){
|
create_config(){
|
||||||
|
check_pyver
|
||||||
while true; do
|
while true; do
|
||||||
player_input="$(zenity --forms --add-entry="Player name (required for some servers)" --add-entry="BattleMetrics API key" --add-entry="Steam API key" --title="DZGUI" --text="DZGUI" $sd_res --separator="│" 2>/dev/null)"
|
player_input="$(zenity --forms --add-entry="Player name (required for some servers)" --add-entry="BattleMetrics API key" --add-entry="Steam API key" --title="DZGUI" --text="DZGUI" $sd_res --separator="│" 2>/dev/null)"
|
||||||
#explicitly setting IFS crashes zenity in loop
|
#explicitly setting IFS crashes zenity in loop
|
||||||
|
@ -298,6 +299,13 @@ run_depcheck(){
|
||||||
exit
|
exit
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
check_pyver(){
|
||||||
|
pyver=$(python --version | awk '{print $2}')
|
||||||
|
if [[ -z $pyver ]] || [[ ${pyver:0:1} -lt 3 ]]; then
|
||||||
|
warn "Requires python >=3.0" &&
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
}
|
||||||
run_varcheck(){
|
run_varcheck(){
|
||||||
source $config_file
|
source $config_file
|
||||||
workshop_dir="$steam_path/steamapps/workshop/content/$aid"
|
workshop_dir="$steam_path/steamapps/workshop/content/$aid"
|
||||||
|
|
Loading…
Reference in a new issue