Skip to content

Commit

Permalink
cleaned up wan_ip plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
napalm255 committed Dec 12, 2014
1 parent 4e8a572 commit 4656d42
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions plugins/wan_ip.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,7 @@ run_plugin() {
local wan_ip

if [ -f "$tmp_file" ]; then
if shell_is_osx || shell_is_bsd; then
stat >/dev/null 2>&1 && is_gnu_stat=false || is_gnu_stat=true
if [ "$is_gnu_stat" == "true" ];then
last_update=$(stat -c "%Y" ${tmp_file})
else
last_update=$(stat -f "%m" ${tmp_file})
fi
elif shell_is_linux || [ -z $is_gnu_stat]; then
last_update=$(stat -c "%Y" ${tmp_file})
fi
last_update=$(stat -c "%Y" ${tmp_file})

time_now=$(date +%s)
update_period=900
Expand Down

0 comments on commit 4656d42

Please sign in to comment.