mirror of
https://github.com/aclist/dztui.git
synced 2026-09-01 04:37:04 +02:00
Compare commits
No commits in common. "6d7b2a1d1967243b971f671598b5ae58bed0df3f" and "ec23a4eb2e3a291934079e4ea10f345ae1e95415" have entirely different histories.
6d7b2a1d19
...
ec23a4eb2e
@ -1,11 +1,5 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
## [5.8.0-beta.2] 2025-07-06
|
|
||||||
## Added
|
|
||||||
- Filter servers by official/unofficial status
|
|
||||||
## Changed
|
|
||||||
- Updated internal versioning of helper files
|
|
||||||
|
|
||||||
## [5.8.0-beta.1] 2025-06-05
|
## [5.8.0-beta.1] 2025-06-05
|
||||||
## Added
|
## Added
|
||||||
- Automatically fetch geolocation records
|
- Automatically fetch geolocation records
|
||||||
|
|||||||
6
dzgui.sh
6
dzgui.sh
@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
|
|
||||||
version=5.8.0-beta.2
|
version=5.8.0-beta.1
|
||||||
|
|
||||||
#CONSTANTS
|
#CONSTANTS
|
||||||
aid=221100
|
aid=221100
|
||||||
@ -585,10 +585,10 @@ fetch_helpers_by_sum(){
|
|||||||
[[ -f "$config_file" ]] && source "$config_file"
|
[[ -f "$config_file" ]] && source "$config_file"
|
||||||
declare -A sums
|
declare -A sums
|
||||||
sums=(
|
sums=(
|
||||||
["ui.py"]="f128a97e744e9e11036d707198feb8a8"
|
["ui.py"]="a6fdbf3e3eb92b7bc78e6ae23882b10b"
|
||||||
["query_v2.py"]="55d339ba02512ac69de288eb3be41067"
|
["query_v2.py"]="55d339ba02512ac69de288eb3be41067"
|
||||||
["vdf2json.py"]="2f49f6f5d3af919bebaab2e9c220f397"
|
["vdf2json.py"]="2f49f6f5d3af919bebaab2e9c220f397"
|
||||||
["funcs"]="94287c75a5ae0a06a95dd439711e6fba"
|
["funcs"]="f6e8b113e586a4bb2ea40c9ee56ebc95"
|
||||||
["lan"]="c62e84ddd1457b71a85ad21da662b9af"
|
["lan"]="c62e84ddd1457b71a85ad21da662b9af"
|
||||||
)
|
)
|
||||||
local author="aclist"
|
local author="aclist"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
version="5.8.0"
|
version=5.6.0
|
||||||
|
|
||||||
#CONSTANTS
|
#CONSTANTS
|
||||||
aid=221100
|
aid=221100
|
||||||
@ -605,20 +605,6 @@ filter_servers(){
|
|||||||
<<< "$filtered" awk -F$separator '!seen[$1]++'
|
<<< "$filtered" awk -F$separator '!seen[$1]++'
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
filter_official(){
|
|
||||||
if [[ ${filters[*]} =~ Official ]]; then
|
|
||||||
echo -n "$filtered"
|
|
||||||
else
|
|
||||||
<<< "$filtered" awk -F$separator '$10 == "Community"'
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
filter_community(){
|
|
||||||
if [[ ${filters[*]} =~ Unoffic ]]; then
|
|
||||||
echo -n "$filtered"
|
|
||||||
else
|
|
||||||
<<< "$filtered" awk -F$separator '$10 == "Official"'
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
filtered=$(filter_perspective)
|
filtered=$(filter_perspective)
|
||||||
filtered=$(filter_full)
|
filtered=$(filter_full)
|
||||||
@ -629,8 +615,6 @@ filter_servers(){
|
|||||||
filtered=$(filter_ascii)
|
filtered=$(filter_ascii)
|
||||||
filtered=$(filter_duplicates)
|
filtered=$(filter_duplicates)
|
||||||
filtered=$(filter_keyword)
|
filtered=$(filter_keyword)
|
||||||
filtered=$(filter_official)
|
|
||||||
filtered=$(filter_community)
|
|
||||||
|
|
||||||
if [[ -z "$filtered" ]]; then
|
if [[ -z "$filtered" ]]; then
|
||||||
logger WARN "Filter result is empty"
|
logger WARN "Filter result is empty"
|
||||||
@ -668,8 +652,7 @@ parse_server_json(){
|
|||||||
"\(.max_players)␞" +
|
"\(.max_players)␞" +
|
||||||
"\(if .gametype == null then "0" elif .gametype|split("lqs")[1] == null then "0" else .gametype|split("lqs")[1]|split(",")[0] end)␞" +
|
"\(if .gametype == null then "0" elif .gametype|split("lqs")[1] == null then "0" else .gametype|split("lqs")[1]|split(",")[0] end)␞" +
|
||||||
"\(.addr|split(":")[0]):\(if .gameport == null then "XXXX" else .gameport end)␞" +
|
"\(.addr|split(":")[0]):\(if .gameport == null then "XXXX" else .gameport end)␞" +
|
||||||
"\(.addr|split(":")[1])␞" +
|
"\(.addr|split(":")[1])"
|
||||||
"\(if .gametype == null then "null" else (.gametype|split(",")|if any(. == "external") then "Community" else "Official" end) end)"
|
|
||||||
' | sort -k1
|
' | sort -k1
|
||||||
}
|
}
|
||||||
align_versions_file(){
|
align_versions_file(){
|
||||||
|
|||||||
@ -17,6 +17,7 @@ import gi
|
|||||||
gi.require_version("Gtk", "3.0")
|
gi.require_version("Gtk", "3.0")
|
||||||
from gi.repository import Gtk, GLib, Gdk, GObject, Pango
|
from gi.repository import Gtk, GLib, Gdk, GObject, Pango
|
||||||
|
|
||||||
|
# 5.7.0
|
||||||
app_name = "DZGUI"
|
app_name = "DZGUI"
|
||||||
|
|
||||||
cache = {}
|
cache = {}
|
||||||
@ -37,7 +38,7 @@ mod_store = Gtk.ListStore(str, str, str, float, str)
|
|||||||
#cf. log_cols
|
#cf. log_cols
|
||||||
log_store = Gtk.ListStore(str, str, str, str)
|
log_store = Gtk.ListStore(str, str, str, str)
|
||||||
#cf. browser_cols
|
#cf. browser_cols
|
||||||
server_store = Gtk.ListStore(str, str, str, str, int, int, int, str, int, str)
|
server_store = Gtk.ListStore(str, str, str, str, int, int, int, str, int)
|
||||||
|
|
||||||
default_tooltip = "Select a row to see its detailed description"
|
default_tooltip = "Select a row to see its detailed description"
|
||||||
server_tooltip = [None, None]
|
server_tooltip = [None, None]
|
||||||
@ -95,9 +96,7 @@ filters = {
|
|||||||
"Full": False,
|
"Full": False,
|
||||||
"Low pop": True,
|
"Low pop": True,
|
||||||
"Non-ASCII": False,
|
"Non-ASCII": False,
|
||||||
"Duplicate": False,
|
"Duplicate": False
|
||||||
"Official": True,
|
|
||||||
"Unoffic.": True,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -554,7 +553,7 @@ def parse_server_rows(data):
|
|||||||
lines = data.stdout.splitlines()
|
lines = data.stdout.splitlines()
|
||||||
reader = csv.reader(lines, delimiter=delimiter)
|
reader = csv.reader(lines, delimiter=delimiter)
|
||||||
try:
|
try:
|
||||||
rows = [[row[0], row[1], row[2], row[3], int(row[4]), int(row[5]), int(row[6]), row[7], int(row[8]), row[9]] for row in reader if row]
|
rows = [[row[0], row[1], row[2], row[3], int(row[4]), int(row[5]), int(row[6]), row[7], int(row[8])] for row in reader if row]
|
||||||
except IndexError:
|
except IndexError:
|
||||||
return 1
|
return 1
|
||||||
for row in rows:
|
for row in rows:
|
||||||
@ -1610,8 +1609,7 @@ class TreeView(Gtk.TreeView):
|
|||||||
if (column_title == "Map"):
|
if (column_title == "Map"):
|
||||||
column.set_fixed_width(300)
|
column.set_fixed_width(300)
|
||||||
|
|
||||||
if i != 10:
|
self.append_column(column)
|
||||||
self.append_column(column)
|
|
||||||
|
|
||||||
self.update_first_col(mode.dict["label"])
|
self.update_first_col(mode.dict["label"])
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user