Use infinite loop

This commit is contained in:
ekzyis 2023-04-20 00:20:46 +02:00
parent eac946690b
commit bc121ce87b
1 changed files with 9 additions and 4 deletions

13
main.go
View File

@ -1,9 +1,14 @@
package main package main
import "time"
func main() { func main() {
stories := FetchHackerNewsTopStories() for {
filtered := CurateContentForStackerNews(&stories) stories := FetchHackerNewsTopStories()
for _, story := range *filtered { filtered := CurateContentForStackerNews(&stories)
PostStoryToStackerNews(&story) for _, story := range *filtered {
PostStoryToStackerNews(&story)
}
time.Sleep(time.Hour)
} }
} }