xenocara/app/xlockmore/etc/xlocksat.pl
2006-11-26 11:07:42 +00:00

9 lines
203 B
Perl

#!/usr/bin/perl -T -w
# xlocksat
require "ctime.pl";
#local($hour) = `/bin/date "+%H:"`;
local($hour) = (localtime)[2];
local($saturation) = (12 - abs($hour - 12)) / 12 ;
printf("%.2f\n", $saturation);