From c6acac3e8626724544cf00ad844ce323a876f233 Mon Sep 17 00:00:00 2001 From: Sami Samhuri Date: Thu, 28 May 2015 13:09:34 -0700 Subject: [PATCH] add 'midnight' preset to lights and flux --- flux | 2 ++ lights | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/flux b/flux index d1d403a..a1228e8 100755 --- a/flux +++ b/flux @@ -35,10 +35,12 @@ def flux(options) month = date.month.to_s day = date.day.to_s if times = TIMES[month][day] + times['midnight'] = '22:30' puts "sunrise: #{times['sunrise']}" puts "morning: #{times['morning']}" puts "sunset: #{times['sunset']}" puts "night: #{times['night']}" + puts "midnight: #{times['midnight']}" time = Time.now hour, min = time.hour, time.min diff --git a/lights b/lights index e9326c7..6bd2fcd 100755 --- a/lights +++ b/lights @@ -32,6 +32,10 @@ TEMPS = { brightness: 160, temp: 2200, }, + 'midnight' => { + brightness: 80, + temp: 1200, + }, } TEMPS['sunny'] = TEMPS['bright'] TEMPS['overcast'] = TEMPS['cloudy']