View launch_app_based_on_environment.sh
# https://stackoverflow.com/questions/22009364/is-there-a-try-catch-command-in-bash | |
echo "checking the network work/home.." | |
sleep 5; | |
{ # try | |
curl www.vmware.com && { # need to wrap using {} | |
echo "try pass; open working app" | |
open "/Applications/Microsoft Outlook.app/" | |
open "/Applications/Firefox.app/" | |
} |
View gtimereport_form_filler.js
javascript:(function () { | |
var date = new Date(); | |
var todayStr = date.getFullYear() + "-" + (date.getMonth() + 1) + "-" + date.getDate(); | |
$("#PeriodStart").val(todayStr); | |
$("#PeriodEnd").val(todayStr); | |
/* The items to choose */ | |
$("input")[3].checked = 'checked'; | |
$("input")[4].checked = 'checked'; | |
$("input")[5].checked = 'checked'; | |
$("#ShowSummary")[0].checked = 'checked'; |