diff options
| author | st33v <github@f3rr3t.com> | 2017-11-19 16:04:59 +1100 |
|---|---|---|
| committer | st33v <github@f3rr3t.com> | 2017-11-19 16:04:59 +1100 |
| commit | eb72452638aa1d51b8652024c3b406aea7ad62a7 (patch) | |
| tree | 9cbe1fc9b76384eaabfd5eda64f674532c71f9f1 /wlanWDprowl.sh | |
| parent | 20636c0881b1501005dc7f10deef866fae39b436 (diff) | |
Timer works and script writes to log.
Diffstat (limited to 'wlanWDprowl.sh')
| -rwxr-xr-x | wlanWDprowl.sh | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/wlanWDprowl.sh b/wlanWDprowl.sh index 3955346..70db23c 100755 --- a/wlanWDprowl.sh +++ b/wlanWDprowl.sh @@ -8,14 +8,17 @@ cd /usr/local/bin # The following block enables private configuration logdir="/path/to/my/log" # overwritten by sourcing from .logdir.config -if [ -e logdir.config ]; then - . logdir.config # source directory name from local config file -else echo "logdir.config does not exist"; exit 1 +if [ -e wlanWDlog.conf ]; then + . wlanWDlog.conf # source directory name from local config file +else echo "wlanWDlog.conf does not exist"; exit 1 fi # end of privacy config # Detect the state of the wireless network adaptor wirelessLink='wlan0' # ymmv -networkctl status ${wirlesessLink} | grep 'State:' - +wlanStatus=$(networkctl status ${wirelessLink} | grep 'State:') +echo ${wlanStatus} +echo $(whoami) +logline=$(date)${wlanStatus} +echo ${logline} >> ${logdir}/wlanStatus.log |
