-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrc-function
More file actions
46 lines (38 loc) · 1.06 KB
/
rc-function
File metadata and controls
46 lines (38 loc) · 1.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
myip ()
{
# используется Geo: https://github.com/jakewmeyer/Geo
#geo -o country
#wan=$(geo -w)A
#dns_wan=$(dig +short -x ${wan})
#echo "Wan: ${wan}-${dns_wan}"
echo "Lan:"
geo -l
geo -o country
echo "---- IPv6: "
ip -6 a | grep inet6 | awk -F " " '{print $2}' | grep -v ::1/128
}
weather()
{
# change Paris to your default location
local request="wttr.in/${1-Moscow?2}"
[ "$(tput cols)" -lt 125 ] && request+='?n'
curl -H "Accept-Language: ${LANG%_*}" --compressed "$request"
}
alias погода="weather"
alias gjujlf="weather"
viamnet()
{
if [ $# -eq "0" ]; then
geo -l
echo "Use: viamnet NAME.viamnet.local"
return 0
fi
dig +short @192.168.250.10 $1
}
vdi ()
{
passwd=$(zenity --password --title="User Password" )
/usr/bin/xfreerdp /f /cert-ignore /smartcard /v:192.168.252.20 /u:ermakov_ds@viamnet.local /p:${passwd} /drive:home,/home/depeche
}
alias z="zsh"
alias remapper="sudo input-remapper-control --command autoload"