How anantasam03/type-cli works
Go-Type CLI is an interactive typing-practice application. The user selects a mode or a score-management flag; during practice, the CLI chooses a prompt, tracks keystrokes and live statistics, and renders the typing screen. On completion it saves the result and displays the leaderboard, then accepts input for another round or exit. Quotes and code snippets are the prompt source; JSON persistence supports both completed rounds and standalone score viewing. The main workflow is shown in the excerpts; no other runtime subsystem is indicated by the README or source index.
Main entry points: main.go CLI and round loop · storage.go Score persistence · highscores.json JSON leaderboard · snippets.go Prompt selection
Components 8
Practice flow
- CLI and round loop
main.go - Prompt selection
snippets.go - WPM and accuracy
main.go
Terminal interface
- Typing and results UI
ui.go
Scorekeeping
- Score persistence
storage.go - JSON leaderboard
highscores.json - Standalone score listing
main.go
Other components
- Terminal user
Connections 9
- Terminal user → CLI and round loop: starts and controls
README.MD - CLI and round loop → Prompt selection: selects prompt
main.go - CLI and round loop → WPM and accuracy: calculates stats
main.go - CLI and round loop → Typing and results UI: renders screens
main.go - CLI and round loop → Score persistence: saves result
main.go - Score persistence → JSON leaderboard: reads and writes
storage.go - Standalone score listing → Score persistence: loads scores
main.go - CLI and round loop → JSON leaderboard: deletes on reset
main.go - CLI and round loop → Standalone score listing: routes score flag
main.go