Skip to content

Instantly share code, notes, and snippets.

View adri72's full-sized avatar
🎯
Focusing

Adriano Chiaretta adri72

🎯
Focusing
View GitHub Profile
@adri72
adri72 / check_ping_nmap.sh
Last active August 29, 2015 13:57
Nagios Plugin allowing to check if an host is alive using nmap (i.e. works even if the host doesn't reply to pings)
#!/bin/bash
# Command paths
CMDNMAP=/usr/bin/nmap
CMDGREP=/bin/grep
# Return codes:
STATE_OK=0
STATE_WARNING=1
STATE_CRITICAL=2
@adri72
adri72 / download_hpenvy17_cto3000_drivers.sh
Created September 29, 2013 13:58
Download all the Windows 7 x64 drivers for the HP Envy 17 CTO-3000 laptop. This bash shell script will download all the drivers' files at once, saving hours of going around through the HP's drivers site, clicking links, saving files, etc. With minor adjustments can be used to download drivers for any other HP product.
#!/bin/sh
sDate=$(date +%m%d%Y)
sScriptName=`basename $0`
sScriptName=${sScriptName%.*}
sDownloadFolder=${sScriptName}_${sDate}
sDriversListingURL="http://h10025.www1.hp.com/ewfrf/wc/softwareCategory?os=4063&lc=en&cc=us&dlc=en&sw_lang=&product=5180698#N788"
sWgetParams="--random-wait --timeout=360 --no-check-certificate --directory-prefix=${sDownloadFolder} --limit-rate=500k --user-agent=Mozilla/5.0 "
@adri72
adri72 / download_hp_spectre_xt_touchsmart_15-4910nr_drivers.sh
Last active December 24, 2015 05:49
Download all the Windows 8 Drivers for the HP Spectre XT TouchSmart 15-4010nr ultrabook. This bash shell script will download all the drivers' files at once, saving hours of going around through the HP's drivers site, clicking links, saving files, etc. With minor adjustments can be used to download drivers for any other HP product.
#!/bin/sh
sDate=$(date +%m%d%Y)
sScriptName=`basename $0`
sScriptName=${sScriptName%.*}
sDownloadFolder=${sScriptName}_${sDate}
#sDriversListingURL="http://h10025.www1.hp.com/ewfrf/wc/softwareCategory?os=4063&lc=en&cc=us&dlc=en&sw_lang=&product=5180698#N788"
sDriversListingURL="http://h10025.www1.hp.com/ewfrf/wc/softwareCategory?os=4063&lc=en&cc=us&dlc=en&sw_lang=&product=5278233"