Advertisement
vicf

termux ~/.bashrc

Dec 8th, 2022
1,065
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.70 KB | None | 0 0
  1. # Android termux .bashrc
  2. # some function
  3. setproxy(){
  4.         if [ -n "$http_proxy" ] ; then
  5.                 echo "$http_proxy"
  6.         else
  7.                 # change to your own proxy IP
  8.                 export http_proxy='192.168.8.175:8118'
  9.         fi
  10. }
  11.  
  12. setsocks5(){
  13.         if [ -n "$http_proxy" ] ; then
  14.                 echo "$http_proxy"
  15.         else
  16.                 # change to your own proxy IP
  17.                 export http_proxy='socks5h://192.168.8.175:9100'
  18.         fi
  19. }
  20.  
  21. unsetproxy(){
  22.         unset http_proxy
  23. }
  24.  
  25. # alias
  26. alias myip='curl -s checkip.amazonaws.com'
  27. alias weather='curl wttr.in/{HK,Tokyo,Taipei}?format=3'
  28.  
  29. # $PATH setting
  30.  
  31. if [ -d "$HOME/bin" ] ; then
  32.     export PATH="$PATH:$HOME/bin"
  33. fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement