fjordgard

A desktop clock application
Log | Files | Refs | README | LICENSE

commit e7228b1d924eb7232c11df61c5fd5df63777669e
parent 95c697219ede6098660ac440625193248985f907
Author: Sylvia Ivory <git@sivory.net>
Date:   Tue, 17 Jun 2025 21:17:15 -0700

Add basic config struct

Diffstat:
Asrc/config.rs | 24++++++++++++++++++++++++
1 file changed, 24 insertions(+), 0 deletions(-)

diff --git a/src/config.rs b/src/config.rs @@ -0,0 +1,24 @@ +pub struct Location { + pub longitude: f64, + pub latitude: f64, + pub name: Option<String> +} + +pub struct Config { + pub timezone: String, + pub time_format: String, + pub collection: String, + pub location: Option<Location>, +} + +impl Default for Config { + fn default() -> Self { + Self { + timezone: String::from("Etc/UTC"), + time_format: String::from("%-I:%-M"), + // https://unsplash.com/collections/1053828/tabliss-official + collection: String::from("1053828"), + location: None + } + } +}