mirror of
https://github.com/aclist/dztui.git
synced 2025-04-03 19:13:00 +02:00
Compare commits
66 commits
4aaca4c77e
...
c414eba41c
Author | SHA1 | Date | |
---|---|---|---|
|
c414eba41c | ||
|
0562d8230d | ||
|
759327e932 | ||
|
540d0ad7e4 | ||
|
47bea45111 | ||
|
d03346b56a | ||
|
54e0762882 | ||
|
0834a86d33 | ||
|
c6a8841614 | ||
|
df92acb7dc | ||
|
a333571f94 | ||
|
05f88b6019 | ||
|
1f31c43fe4 | ||
|
0763416903 | ||
|
3b384c5a4d | ||
|
afffc90abc | ||
|
70db7b45b3 | ||
|
aac8558079 | ||
|
ac8ff2febf | ||
|
6369d895fd | ||
|
7413f7c029 | ||
|
2c5da88e06 | ||
|
3cb6175436 | ||
|
3739f19ab2 | ||
|
2da4d001d6 | ||
|
5d61a1f513 | ||
|
56c80d187b | ||
|
e08f66cdcb | ||
|
48fee301bb | ||
|
20511f5661 | ||
|
d2e8333ba9 | ||
|
5d37039064 | ||
|
ce44cdbc54 | ||
|
5b2738420e | ||
|
1e29288e2a | ||
|
745cc06091 | ||
|
0311cc8a95 | ||
|
7c3521cf97 | ||
|
bb0eefadd2 | ||
|
7eb5a4fac5 | ||
|
ebce329c3d | ||
|
23464d3b51 | ||
|
602a7b8edc | ||
|
59c58a1df5 | ||
|
830318d98e | ||
|
271c3e6197 | ||
|
1ab9634069 | ||
|
8666b0055a | ||
|
406554e011 | ||
|
5334d07f7f | ||
|
6cab96d1f8 | ||
|
bc94d989d4 | ||
|
e4fff5f242 | ||
|
53f2fe922a | ||
|
800f68a1b7 | ||
|
c6c377e8b9 | ||
|
7a68d7e097 | ||
|
a8f51280e8 | ||
|
c19346529b | ||
|
85451f765b | ||
|
5a144f7815 | ||
2370e81403 | |||
|
bae6a57e1e | ||
|
c2c7b37b90 | ||
|
8e6cf7e792 | ||
|
98868073a5 |
8 changed files with 196 additions and 3 deletions
53
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
Normal file
53
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
Normal file
|
@ -0,0 +1,53 @@
|
|||
name: Bug report
|
||||
description: Submit bugs that affect functionality here
|
||||
title: "[BUG] Your title here"
|
||||
labels: ["bug"]
|
||||
assignees:
|
||||
- aclist
|
||||
body:
|
||||
- type: checkboxes
|
||||
id: kb
|
||||
attributes:
|
||||
label: Did you check if this issue already exists?
|
||||
options:
|
||||
- label: I have checked the [Knowledge Base](https://aclist.github.io/dzgui/kb.html) and searched through [past issues](https://github.com/aclist/dztui/issues?q=is%3Aissue+is%3Aclosed) and did not find my issue there.
|
||||
required: true
|
||||
- type: dropdown
|
||||
id: device
|
||||
attributes:
|
||||
label: Device type
|
||||
options:
|
||||
- Desktop PC
|
||||
- Steam Deck
|
||||
default: 0
|
||||
validations:
|
||||
required: true
|
||||
- type: input
|
||||
id: version
|
||||
attributes:
|
||||
label: DZGUI version
|
||||
validations:
|
||||
required: true
|
||||
placeholder: "5.6.0"
|
||||
- type: input
|
||||
id: distro
|
||||
attributes:
|
||||
label: Linux distribution
|
||||
validations:
|
||||
required: true
|
||||
placeholder: "Arch Linux"
|
||||
- type: textarea
|
||||
id: what-happened
|
||||
attributes:
|
||||
label: Describe the bug
|
||||
description: What did you expect to happen?
|
||||
placeholder: "E.g., When doing X, Y occurred. Include as much detail as possible."
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: logs
|
||||
attributes:
|
||||
label: Additional log output
|
||||
description: Attach the file `$HOME/.local/state/dzgui/DZGUI_DEBUG.log` by clicking this area to highlight it and then dragging the file in.
|
||||
validations:
|
||||
required: false
|
1
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
1
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
blank_issues_enabled: false
|
47
.github/ISSUE_TEMPLATE/feature.yml
vendored
Normal file
47
.github/ISSUE_TEMPLATE/feature.yml
vendored
Normal file
|
@ -0,0 +1,47 @@
|
|||
name: Feature suggestion
|
||||
description: Submit requests for new features here
|
||||
title: "[FEAT] Your title here"
|
||||
labels: ["enhancement"]
|
||||
assignees:
|
||||
- aclist
|
||||
body:
|
||||
- type: dropdown
|
||||
id: device
|
||||
attributes:
|
||||
label: Device type
|
||||
options:
|
||||
- Desktop PC
|
||||
- Steam Deck
|
||||
default: 0
|
||||
validations:
|
||||
required: true
|
||||
- type: input
|
||||
id: version
|
||||
attributes:
|
||||
label: DZGUI version
|
||||
validations:
|
||||
required: true
|
||||
placeholder: "5.6.0"
|
||||
- type: input
|
||||
id: distro
|
||||
attributes:
|
||||
label: Linux distribution
|
||||
validations:
|
||||
required: true
|
||||
placeholder: "Arch Linux"
|
||||
- type: textarea
|
||||
id: what-happened
|
||||
attributes:
|
||||
label: Describe the feature
|
||||
description: A clear and detailed description
|
||||
placeholder: "E.g., Add a dialog to the Options menu that automatically lets the user do Y"
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: why
|
||||
attributes:
|
||||
label: Describe the benefit
|
||||
description: How will this feature benefit large numbers of users?
|
||||
placeholder: "E.g., Currently, users have to manually do X to achieve Y. Implementing this feature would achieve A, B, and C."
|
||||
validations:
|
||||
required: true
|
46
.github/ISSUE_TEMPLATE/trouble.yml
vendored
Normal file
46
.github/ISSUE_TEMPLATE/trouble.yml
vendored
Normal file
|
@ -0,0 +1,46 @@
|
|||
name: Troubleshooting
|
||||
description: Submit user error/troubleshooting questions here
|
||||
title: "[HELP] Your title here"
|
||||
labels: ["troubleshooting"]
|
||||
assignees:
|
||||
- aclist
|
||||
body:
|
||||
- type: dropdown
|
||||
id: device
|
||||
attributes:
|
||||
label: Device type
|
||||
options:
|
||||
- Desktop PC
|
||||
- Steam Deck
|
||||
default: 0
|
||||
validations:
|
||||
required: true
|
||||
- type: input
|
||||
id: version
|
||||
attributes:
|
||||
label: DZGUI version
|
||||
validations:
|
||||
required: true
|
||||
placeholder: "5.6.0"
|
||||
- type: input
|
||||
id: distro
|
||||
attributes:
|
||||
label: Linux distribution
|
||||
validations:
|
||||
required: true
|
||||
placeholder: "Arch Linux"
|
||||
- type: textarea
|
||||
id: what-happened
|
||||
attributes:
|
||||
label: Describe the issue
|
||||
description: A detailed description. What did you expect to happen?
|
||||
placeholder: "Include as much detail as possible and state the steps leading up to the problem. E.g., First I do this, then I do this, then this happens."
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: logs
|
||||
attributes:
|
||||
label: Additional log output
|
||||
description: Attach the file `$HOME/.local/state/dzgui/DZGUI_DEBUG.log` by clicking this area to highlight it and then dragging the file in.
|
||||
validations:
|
||||
required: false
|
|
@ -1,5 +1,13 @@
|
|||
# Changelog
|
||||
|
||||
## [5.6.2] 2024-01-22
|
||||
### Fixed
|
||||
- Resolve regression introduced with IP resolution feature in 5.6.0 (restores functionality of right-click action: Add to My Servers)
|
||||
|
||||
## [5.6.1] 2024-01-10
|
||||
### Fixed
|
||||
- Add fallback support for jq 1.6
|
||||
|
||||
## [5.6.0] 2024-01-06
|
||||
### Added
|
||||
- Application header bar and controls
|
||||
|
|
6
dzgui.sh
6
dzgui.sh
|
@ -1,7 +1,7 @@
|
|||
#!/usr/bin/env bash
|
||||
set -o pipefail
|
||||
|
||||
version=5.6.1
|
||||
version=5.6.2
|
||||
|
||||
#CONSTANTS
|
||||
aid=221100
|
||||
|
@ -587,10 +587,10 @@ fetch_helpers_by_sum(){
|
|||
[[ -f "$config_file" ]] && source "$config_file"
|
||||
declare -A sums
|
||||
sums=(
|
||||
["ui.py"]="d3ad9153d8599bea0eede9fd3121ee8e"
|
||||
["ui.py"]="5a876efacf208d12b5fe761996425412"
|
||||
["query_v2.py"]="55d339ba02512ac69de288eb3be41067"
|
||||
["vdf2json.py"]="2f49f6f5d3af919bebaab2e9c220f397"
|
||||
["funcs"]="6a1c7ce585d9b76e2e75dba9d4295f8d"
|
||||
["funcs"]="417bd5eaffbefc905a843985c691dc64"
|
||||
["lan"]="c62e84ddd1457b71a85ad21da662b9af"
|
||||
)
|
||||
local author="aclist"
|
||||
|
|
|
@ -130,6 +130,7 @@ declare -A funcs=(
|
|||
["Remove from my servers"]="update_favs_from_table"
|
||||
["Remove from history"]="remove_from_history"
|
||||
["Force update local mods"]="force_update"
|
||||
["Resolve IP"]="resolve_ip"
|
||||
["Handshake"]="final_handshake"
|
||||
["get_player_count"]="get_player_count"
|
||||
["lan_scan"]="lan_scan"
|
||||
|
@ -161,6 +162,33 @@ find_stale_mods(){
|
|||
printf ""
|
||||
return 99
|
||||
}
|
||||
resolve_ip(){
|
||||
shift
|
||||
local res
|
||||
local record="$1"
|
||||
local ip=$(<<< "$record" awk -F: '{print $1}')
|
||||
local qport=$(<<< "$record" awk -F: '{print $3}')
|
||||
res=$(a2s $ip $qport info)
|
||||
if [[ ! $? -eq 0 ]]; then
|
||||
printf "Server timed out \n"
|
||||
return 1
|
||||
fi
|
||||
local gport=$(<<< "$res" jq -r '.[].gameport')
|
||||
if [[ -z $gport ]]; then
|
||||
printf "Failed to resolve server metadata\n"
|
||||
return 1
|
||||
fi
|
||||
|
||||
# incoming input can only be 'remove' or 'add'
|
||||
# record is in favs => implies deletion
|
||||
# record not in favs => implies addition
|
||||
resolved_record="$ip:$gport:$qport"
|
||||
if [[ ${ip_list[*]} =~ $resolved_record ]]; then
|
||||
remove_from_favs "$resolved_record"
|
||||
else
|
||||
add_to_favs "$resolved_record"
|
||||
fi
|
||||
}
|
||||
get_player_count(){
|
||||
shift
|
||||
local res
|
||||
|
|
|
@ -1814,10 +1814,16 @@ class TreeView(Gtk.TreeView):
|
|||
|
||||
|
||||
def format_metadata(row_sel):
|
||||
# this function is recycled for the add by ip/id methods +
|
||||
# the right-click context menu (add/remove servers)
|
||||
# in the latter case, there is no metadata to update
|
||||
# see grid.update_statusbar(), so the returned row is None
|
||||
row = None
|
||||
for i in RowType:
|
||||
if i.dict["label"] == row_sel:
|
||||
row = i
|
||||
prefix = i.dict["tooltip"]
|
||||
break
|
||||
vals = {
|
||||
"branch": config_vals[0],
|
||||
"debug": config_vals[1],
|
||||
|
@ -1827,6 +1833,8 @@ def format_metadata(row_sel):
|
|||
"preferred_client": config_vals[5],
|
||||
"fullscreen": config_vals[6]
|
||||
}
|
||||
if row is None:
|
||||
return None
|
||||
try:
|
||||
alt = row.dict["alt"]
|
||||
default = row.dict["default"]
|
||||
|
@ -2396,6 +2404,8 @@ class Grid(Gtk.Grid):
|
|||
return True
|
||||
|
||||
def update_statusbar(self, string):
|
||||
if string is None:
|
||||
return
|
||||
meta = self.bar.get_context_id("Statusbar")
|
||||
self.bar.push(meta, string)
|
||||
|
||||
|
|
Loading…
Reference in a new issue