Skip to content

Instantly share code, notes, and snippets.

@jakoss
Created August 7, 2015 20:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jakoss/0bb7300b529e441ba14e to your computer and use it in GitHub Desktop.
Save jakoss/0bb7300b529e441ba14e to your computer and use it in GitHub Desktop.
Iterate through the all charsets in briandowns/spinner
package main
import (
"bufio"
"fmt"
"os"
"time"
"github.com/briandowns/spinner"
)
func main() {
for i := 0; i < 36; i++ {
s := spinner.New(spinner.CharSets[i], 100*time.Millisecond)
fmt.Printf("Charset [%d]:\n", i)
s.Start()
reader := bufio.NewReader(os.Stdin)
reader.ReadString('\n')
s.Stop()
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment