mirror of
https://github.com/cjdenio/jia.git
synced 2024-11-21 23:23:39 +00:00
Possibly fix timezone thing
This commit is contained in:
parent
f0f865811a
commit
2903509a87
3 changed files with 8 additions and 6 deletions
|
@ -15,6 +15,8 @@ func main() {
|
||||||
fmt.Println("Starting Jia…")
|
fmt.Println("Starting Jia…")
|
||||||
config := jia.NewConfig()
|
config := jia.NewConfig()
|
||||||
|
|
||||||
|
fmt.Printf("%+v\n", config.Events)
|
||||||
|
|
||||||
// Start receiving messages
|
// Start receiving messages
|
||||||
fmt.Printf("Listening on port %d\n", config.Port)
|
fmt.Printf("Listening on port %d\n", config.Port)
|
||||||
jia.StartServer(config)
|
jia.StartServer(config)
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
- name: Test Event
|
- name: Test Event
|
||||||
start: 8:00 May 2, 2021 EDT
|
start: 8:00 May 2, 2021 -0400
|
||||||
end: 7:59 May 3, 2021 EDT
|
end: 7:59 May 3, 2021 -0400
|
||||||
- name: May Counting
|
- name: May Counting
|
||||||
start: 8:00 May 3, 2021 EDT
|
start: 8:00 May 3, 2021 -0400
|
||||||
end: 20:00 May 31, 2021 EDT
|
end: 20:00 May 31, 2021 -0400
|
||||||
|
|
|
@ -53,8 +53,8 @@ func NewConfig() *Config {
|
||||||
}
|
}
|
||||||
|
|
||||||
for i, event := range events {
|
for i, event := range events {
|
||||||
events[i].StartTime, _ = time.Parse("15:04 Jan 2, 2006 MST", event.StartString)
|
events[i].StartTime, _ = time.Parse("15:04 Jan 2, 2006 -0700", event.StartString)
|
||||||
events[i].EndTime, _ = time.Parse("15:04 Jan 2, 2006 MST", event.EndString)
|
events[i].EndTime, _ = time.Parse("15:04 Jan 2, 2006 -0700", event.EndString)
|
||||||
}
|
}
|
||||||
|
|
||||||
return &Config{
|
return &Config{
|
||||||
|
|
Loading…
Reference in a new issue