mirror of
https://github.com/neoromantique/dotfiles.git
synced 2026-03-13 21:53:20 +03:00
update
This commit is contained in:
@@ -37,11 +37,11 @@
|
|||||||
|
|
||||||
# Device-specific configuration
|
# Device-specific configuration
|
||||||
{{- if eq $deviceProfile "desktop" }}
|
{{- if eq $deviceProfile "desktop" }}
|
||||||
primaryMonitor = "DP-1"
|
primaryMonitor = "DP-2"
|
||||||
secondaryMonitor = "DP-2"
|
secondaryMonitor = ""
|
||||||
primaryResolution = "2560x1440@165"
|
primaryResolution = "2560x1440@144"
|
||||||
secondaryResolution = "2560x1440@60"
|
secondaryResolution = ""
|
||||||
hasMultipleMonitors = true
|
hasMultipleMonitors = false
|
||||||
hasTouchpad = false
|
hasTouchpad = false
|
||||||
hasBattery = false
|
hasBattery = false
|
||||||
idleTimeout = 300
|
idleTimeout = 300
|
||||||
|
|||||||
@@ -127,6 +127,7 @@ def build_menu():
|
|||||||
lines.append(" ● Exit Node Active - Disconnect")
|
lines.append(" ● Exit Node Active - Disconnect")
|
||||||
for node in get_ts_exit_nodes():
|
for node in get_ts_exit_nodes():
|
||||||
lines.append(f" ○ {node['hostname']} ({node['country']}/{node['city']})")
|
lines.append(f" ○ {node['hostname']} ({node['country']}/{node['city']})")
|
||||||
|
lines.append(" ⊘ Tailscale Down")
|
||||||
else:
|
else:
|
||||||
lines.append(" ○ Start Tailscale")
|
lines.append(" ○ Start Tailscale")
|
||||||
|
|
||||||
@@ -205,6 +206,11 @@ def handle_selection(selection):
|
|||||||
notify("Tailscale started")
|
notify("Tailscale started")
|
||||||
return
|
return
|
||||||
|
|
||||||
|
if clean == "Tailscale Down":
|
||||||
|
run(["tailscale", "down"])
|
||||||
|
notify("Tailscale stopped")
|
||||||
|
return
|
||||||
|
|
||||||
for node in ts_exit_nodes:
|
for node in ts_exit_nodes:
|
||||||
if node["hostname"] in clean or node["short"] in clean:
|
if node["hostname"] in clean or node["short"] in clean:
|
||||||
disconnect_all_wg()
|
disconnect_all_wg()
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ get_status() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Check Tailscale
|
# Check Tailscale
|
||||||
if command -v tailscale &>/dev/null; then
|
if command -v tailscale &>/dev/null && tailscale status &>/dev/null; then
|
||||||
ts_json=$(tailscale status --json 2>/dev/null)
|
ts_json=$(tailscale status --json 2>/dev/null)
|
||||||
if [[ -n "$ts_json" ]]; then
|
if [[ -n "$ts_json" ]]; then
|
||||||
ts_state=$(echo "$ts_json" | jq -r '.BackendState // empty')
|
ts_state=$(echo "$ts_json" | jq -r '.BackendState // empty')
|
||||||
|
|||||||
Reference in New Issue
Block a user