Stats script: Difference between revisions

From Cheatsheet
Jump to navigation Jump to search
Created page with 'Alright to use my custom response tracking script do the following. vim /bin/stats Paste in the following. <pre> #!/bin/bash # compiled by mshooltz and zeadie PID=$$ curl -s…'
 
m 5 revisions
 
(4 intermediate revisions by the same user not shown)
Line 5: Line 5:
Paste in the following.
Paste in the following.


<pre>
#!/bin/bash
# compiled by mshooltz and zeadie


PID=$$
#!/bin/bash
curl -s --progress-bar -b "entropy-support-login=mshooltz@liquidweb.com" -u mshooltz:vovrogue1 https://hd.int.liquidweb.com/stats/detail.mhtml | lynx -dump -stdin -nolist -width=350 | grep -A500 Responses > /tmp/$PID.stats
# compiled by mshooltz
grep -A2 Responses /tmp/$PID.stats
## add or remove people in the following Fashion
PID=$$
###            #grep (HD username) /tmp/$PID.stats
curl -s --progress-bar -b "entropy-support-login=mshooltz@liquidweb.com" -u <font color=red>(HD usename here):(hdpassword here)</font> https://hd.int.liquidweb.com/stats/detail.mhtml | lynx -dump -stdin -nolist -width=350 | grep -A500 Responses > /tmp/$PID.stats
grep -A2 Responses /tmp/$PID.stats
## add or remove people in the following Fashion
#
#            grep <font color=red>(HD username)</font> /tmp/$PID.stats
#
echo ""
echo "ME"
        grep <font color=red>(HD username)</font> /tmp/$PID.stats
echo ""
echo ""
echo "Support"
echo ""
echo "1st shift"
        grep rhatt /tmp/$PID.stats
echo ""
echo "2cnd shift"
        grep rdrumheller /tmp/$PID.stats
echo ""
echo "3rd shift"
        grep jhayhoe /tmp/$PID.stats
rm -f /tmp/$PID.stats


echo ""
echo "ME"
        grep (HD username) /tmp/$PID.stats
echo ""
echo ""
echo "Support"
echo ""
echo "1st shift"
        grep rhatt /tmp/$PID.stats
echo ""
echo "2cnd shift"
        grep rdrumheller /tmp/$PID.stats
echo ""
echo "3rd shift"
        grep jhayhoe /tmp/$PID.stats
rm -f /tmp/$PID.stats
</pre>


Now you will need to give the file execute perms.
Now you will need to give the file execute perms.

Latest revision as of 23:51, 23 October 2014

Alright to use my custom response tracking script do the following.

vim /bin/stats

Paste in the following.


#!/bin/bash
# compiled by mshooltz

PID=$$
curl -s --progress-bar -b "entropy-support-login=mshooltz@liquidweb.com" -u (HD usename here):(hdpassword here) https://hd.int.liquidweb.com/stats/detail.mhtml | lynx -dump -stdin -nolist -width=350 | grep -A500 Responses > /tmp/$PID.stats
grep -A2 Responses /tmp/$PID.stats

## add or remove people in the following Fashion
#
#             grep (HD username) /tmp/$PID.stats
#

echo ""
echo "ME"
       grep (HD username) /tmp/$PID.stats
echo ""
echo ""
echo "Support"
echo ""
echo "1st shift"
        grep rhatt /tmp/$PID.stats
echo ""

echo "2cnd shift"
        grep rdrumheller /tmp/$PID.stats
echo ""

echo "3rd shift"
        grep jhayhoe /tmp/$PID.stats 


rm -f /tmp/$PID.stats


Now you will need to give the file execute perms.

chmod +x /bin/stats

Now all you have to do at the command line for your workstation, is type stats. Also you can add whoever you would like to track, in the file I have left a few examples in the file for you.