grc.zsh (1002B)
1if [[ "$TERM" != dumb ]] && (( $+commands[grc] )) ; then 2 3 # Supported commands 4 cmds=( 5 as 6 ant 7 blkid 8 cc 9 configure 10 cvs 11 df 12 diff 13 dig 14 dnf 15 docker 16 docker-compose 17 docker-machine 18 du 19 env 20 fdisk 21 findmnt 22 free 23 g++ 24 gas 25 gcc 26 getfacl 27 getsebool 28 gmake 29 id 30 ifconfig 31 iostat 32 ip 33 iptables 34 iwconfig 35 journalctl 36 kubectl 37 last 38 ldap 39 lolcat 40 ld 41 lsattr 42 lsblk 43 lsmod 44 lsof 45 lspci 46 make 47 mount 48 mtr 49 mvn 50 netstat 51 nmap 52 ntpdate 53 php 54 ping 55 ping6 56 proftpd 57 ps 58 sar 59 semanage 60 sensors 61 showmount 62 ss 63 stat 64 sysctl 65 systemctl 66 tcpdump 67 traceroute 68 traceroute6 69 tune2fs 70 uptime 71 vmstat 72 wdiff 73 whois 74 ) 75 76 # Set alias for available commands. 77 for cmd in $cmds ; do 78 if (( $+commands[$cmd] )) ; then 79 alias $cmd="grc /bin/$cmd" 80 fi 81 done 82 83 # Clean up variables 84 unset cmds cmd 85fi