New backup 2026-01-04 17:15:02
This commit is contained in:
parent
13fb8b16c4
commit
69b6bc50a0
2 changed files with 3 additions and 2 deletions
|
|
@ -21,7 +21,7 @@
|
|||
"${( vpn.name =~ '^[Hh]ome.*' ?
|
||||
( vpn.name =~ '.*[Ff]ull.*' ? '' : '') :
|
||||
( vpn.name =~ '^pia-.*' ?
|
||||
( vpn.name =~ '.*sea.*' ? '' : '' ) :
|
||||
( vpn.name =~ '.*local.*' ? '' : '' ) :
|
||||
'' )
|
||||
)} ${( vpn.active == 'yes' ? '' : '' )}"
|
||||
)
|
||||
|
|
|
|||
|
|
@ -3,7 +3,8 @@
|
|||
|
||||
function ifstatus(){
|
||||
jq -cs '{"interfaces": [(.[0].devs[] | select((.type=="wifi") or (.type=="ethernet")))]} * {"vpns": [(.[1].cons[] | select((.type=="vpn") or (.type=="wireguard")))]}' <<<$( \
|
||||
nmcli --terse -f DEVICE,TYPE,STATE,CONNECTION d s | column -t -n 'devs' --table-columns device,type,state,connection -s ':' -J; \
|
||||
# nmcli --terse -f DEVICE,TYPE,STATE,CONNECTION d s | column -t -n 'devs' --table-columns device,type,state,connection -s ':' -J; \
|
||||
nmcli --terse -f DEVICE,TYPE,STATE,CONNECTION d s | sed 's/\\:/###/g;s/:/\;/g;s/###/:/g' | column -t -n 'devs' --table-columns device,type,state,connection -s ';' -J; \
|
||||
nmcli --terse -f NAME,TYPE,ACTIVE,DEVICE c s | column -t -n 'cons' --table-columns name,type,active,device -s ':' -J)
|
||||
# [ .devices[] | select((.type=="wifi") or (.type=="ethernet")) ]
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue