Skip to content
Twitcher. The ticker with update
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Makefile
README.md
twitcher.go
twitcher_test.go

README.md

Twitcher

It's like a tick but more anoying

twitcher := twitcher.NewTwitcher(time.Seconds * 5)
twitcher.Do(func() {
        print("I'm going to be executed every 5 seconds\n")
})

Update the execution time:

twitcher.Update(time.Hour * 2)

You can also access the channel without fancy stuff:

for {
        <-twitcher.C
}
You can’t perform that action at this time.