Skip to content

vamshi1188/SyntaxRush

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

16 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿš€ SyntaxRush - Elite Code Typing Trainer

๐Ÿ’ช The Ultimate Muscle-Powered Code Typing Experience
Practice real code. Build typing stamina. Master syntax.

๐Ÿง โšก SyntaxRush is an advanced, gamified terminal application that transforms code typing practice into an engaging fitness experience. Built for developers who want to type code like a pro!

โœจ Key Features

๏ฟฝ Muscle Power Indicator (MPI) - Revolutionary Typing Endurance System

  • ๐Ÿ’ช Real-time Power Tracking: Dynamic muscle power calculation based on keystroke efficiency
  • ๐Ÿ† Achievement System: Unlock "Finger Fury", "On Fire", and "Zen Mode" achievements
  • ๐Ÿ“ˆ Stamina Monitoring: Track typing endurance and detect fatigue patterns
  • โšก Power States: 6 dynamic states from "Ready to Type" to "Burnout" with visual feedback
  • ๐Ÿ”ฅ Streak Tracking: Monitor consecutive correct characters with milestone celebrations
  • ๐ŸŽฏ Consistency Analysis: Rhythm detection and keystroke timing optimization

๐Ÿง  Smart Code Practice

  • ๐Ÿ“ Multi-language Support: Go, Python, JavaScript, C++, TypeScript, Rust, Java
  • ๐Ÿš€ Quick File Loading: Smart shortcuts (go, py, js, cpp) or custom file paths
  • โœจ Live Color Feedback: Green/red character highlighting with persistent history
  • ๐Ÿ“– Unified Display: Code context and typing practice in one seamless interface
  • ๐ŸŽจ Leading Space Intelligence: Skip indentation, focus on actual code content

๐Ÿ”Š Premium Audio Experience

  • ๐ŸŽต High-Quality Audio: Oto v2 library for crisp 44.1kHz sound
  • โŒ Error Feedback: Instant audio cues for typing mistakes
  • โœ… Success Sounds: Satisfying completion audio rewards
  • ๐Ÿ”‡ Graceful Fallback: Terminal bell backup if audio fails

๐Ÿ“Š Comprehensive Analytics

  • โฑ๏ธ Real-time Metrics: WPM, CPM, accuracy, time tracking
  • ๐ŸŽฏ Session Analysis: Detailed performance breakdown
  • ๐Ÿ’พ Typing History: Color-coded progress preservation across lines
  • ๐Ÿ“ˆ Power Statistics: Peak performance, stamina levels, consistency scores

๐ŸŽฎ Power States & Achievements

Status Icon Trigger Condition Description
๐Ÿง˜ Zen Mode ๐Ÿง˜ 95%+ consistency + 80+ CPM + 50+ streak Ultimate flow state
๐Ÿ’ช Full Power ๐Ÿ’ช 80%+ stamina + 60+ CPM Peak performance
โšก Good Flow โšก 60%+ stamina + steady rhythm Solid pace
๐Ÿ’ค Fatigue Mode ๏ฟฝ Declining performance Focus needed
๐Ÿ”ฅ Rest Needed ๐Ÿ”ฅ Critical performance drop Break time
๐Ÿš€ Ready to Type ๐Ÿš€ Initial state Let's begin!

๐Ÿ† Achievement Unlocks

  • ๐Ÿ† FINGER FURY UNLEASHED! - 100+ character perfect streak
  • ๐Ÿ”ฅ ON FIRE! - 50+ character perfect streak
  • โšก GAINING MOMENTUM! - 25+ character perfect streak

๐Ÿš€ Quick Start

Prerequisites

  • Go 1.21+ (Download from golang.org)
  • Color-capable terminal (most modern terminals)

Installation

Option 1: Quick Install (Recommended)

# Clone and install globally
git clone https://github.com/vamshi1188/SyntaxRush.git
cd SyntaxRush
./install.sh

# Start practicing immediately
syntaxrush practice go

Option 2: Manual Installation

# Clone the repository
git clone https://github.com/vamshi1188/SyntaxRush.git
cd SyntaxRush

# Install dependencies
go mod tidy

# Build the application
go build -o syntaxrush

# Run SyntaxRush
./syntaxrush practice

Option 3: Go Install (Coming Soon)

# Install directly with Go
go install github.com/vamshi1188/SyntaxRush@latest

# Use anywhere
syntaxrush practice main.go

Shell Completion (Optional)

# Enable auto-completion for commands and files
./setup-completion.sh

๐ŸŽฏ How to Use

๐Ÿš€ Getting Started

  1. Install SyntaxRush globally:

    ./install.sh
  2. Start practicing immediately:

    # Practice with built-in samples
    syntaxrush practice go       # Go calculator
    syntaxrush practice python   # Python data processor
    syntaxrush practice js       # JavaScript task manager
    syntaxrush practice cpp      # C++ grade system
    
    # Practice with your own files
    syntaxrush practice main.go
    syntaxrush practice src/app.py
    syntaxrush practice ~/projects/calculator.js
  3. Use CLI flags for customization:

    syntaxrush practice --quick main.go    # Skip welcome screen
    syntaxrush practice --mute app.py      # Disable audio
    syntaxrush practice --stats hello.go   # Show detailed stats

๐Ÿ’ช CLI Commands

Command Description Example
practice [file] Start typing practice syntaxrush practice main.go
practice go Practice with Go sample syntaxrush practice go
practice python Practice with Python sample syntaxrush practice python
stats View performance statistics syntaxrush stats
config Configure settings syntaxrush config
version Show version info syntaxrush version
--help Show help for any command syntaxrush practice --help

๐ŸŽ›๏ธ CLI Flags

Flag Short Description Example
--quick -q Skip welcome screen syntaxrush practice -q main.go
--mute -m Disable audio feedback syntaxrush practice -m app.py
--stats -s Show detailed statistics syntaxrush practice -s hello.go
--difficulty -d Set difficulty level syntaxrush practice -d hard main.go
--help -h Show command help syntaxrush practice -h

๐Ÿ’ช Practice Session

  1. Start Typing: Begin typing the displayed code
  2. Watch Your Power: Monitor your Muscle Power Indicator in real-time
  3. Build Streaks: Aim for long correct character streaks
  4. Maintain Flow: Keep consistent rhythm for maximum power
  5. Complete Lines: Press Enter when you finish each line

๐Ÿ“Š Understanding Your Results

Real-time Display

๐Ÿš€ Ready to Type โ”‚ ๐Ÿ’ช Power: [โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆ] 100% โ”‚ ๐Ÿ”ฅ Streak: 0 โ”‚ โšก Peak: 1

โฑ๏ธ Time: 00:00 โ”‚ ๐ŸŽฏ Accuracy: 100.0% โ”‚ โšก WPM: 0 โ”‚ ๐Ÿ“Š CPM: 0 โ”‚ โŒ Mistakes: 0

Final Session Summary

  • ๐Ÿ“ Session Info: File name, lines completed, total time
  • ๐ŸŽฏ Performance: WPM, CPM, accuracy, mistakes
  • ๐Ÿ’ช MPI Results: Power states, peak performance, streaks
  • ๐Ÿ† Achievements: Unlocked achievements and milestones
  • ๐Ÿ’ก Health Insights: Fatigue detection and endurance analysis

โŒจ๏ธ Controls & Shortcuts

Main Controls

Key Action Description
Enter / Space Start Practice Begin typing session with current file
Ctrl+U Upload File Load a new code file for practice
Ctrl+R Retry Session Restart current file from beginning
Esc Return to Menu Go back to welcome screen
Q Quit Exit SyntaxRush

File Loading Shortcuts

Shortcut File Language
go sample.go Go programming
py sample.py Python
js sample.js JavaScript
cpp sample.cpp C++

During Practice

  • No Backspace: Practice forward-only typing (realistic coding)
  • Audio Feedback: Hear mistake alerts and success sounds
  • Live Color Coding: See your progress in real-time
  • Automatic Spacing: Skip leading indentation, focus on code

๐ŸŽจ Visual Experience

Color Coding System

  • ๐ŸŸข Green Characters: Correctly typed
  • ๐Ÿ”ด Red Characters: Mistakes (shows expected character)
  • โšช Gray Characters: Not yet typed or indentation
  • ๐ŸŸก Yellow Cursor: Current typing position
  • ๐ŸŸ  Orange: Extra characters beyond line end

Power Bar Display

๐Ÿ’ช Full Power โ”‚ ๐Ÿ’ช Power: [โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆ] 100% โ”‚ ๐Ÿ”ฅ Streak: 25 โ”‚ โšก Peak: 150

๐Ÿ—๏ธ Technical Architecture

Built With

  • ๐Ÿ”ง Go 1.21+: Core application language
  • ๐Ÿ–ฅ๏ธ Bubble Tea: Elegant TUI framework
  • ๐ŸŽจ Lip Gloss: Beautiful terminal styling
  • ๐Ÿ”Š Oto v2: High-quality cross-platform audio
  • โšก tcell v2: Advanced terminal capabilities

Project Structure

SyntaxRush/
โ”œโ”€โ”€ main.go              # Application entry point
โ”œโ”€โ”€ ui/                  # User interface components
โ”‚   โ”œโ”€โ”€ model.go         # Application state & logic
โ”‚   โ””โ”€โ”€ view.go          # UI rendering & layout
โ”œโ”€โ”€ core/                # Core functionality
โ”‚   โ”œโ”€โ”€ audio.go         # Audio management
โ”‚   โ”œโ”€โ”€ metrics.go       # Performance tracking
โ”‚   โ”œโ”€โ”€ muscle_power.go  # MPI system
โ”‚   โ”œโ”€โ”€ parser.go        # File parsing
โ”‚   โ””โ”€โ”€ timer.go         # Time management
โ”œโ”€โ”€ theme/               # Visual theming
โ”‚   โ””โ”€โ”€ theme.go         # Color schemes & styles
โ”œโ”€โ”€ assets/              # Sample files
โ”‚   โ”œโ”€โ”€ sample.go        # Go calculator
โ”‚   โ”œโ”€โ”€ sample.py        # Python data processor  
โ”‚   โ”œโ”€โ”€ sample.js        # JavaScript task manager
โ”‚   โ””โ”€โ”€ sample.cpp       # C++ grade system
โ””โ”€โ”€ README.md            # This file

๐Ÿ“š Sample Files

๐Ÿšง Supported Languages

SyntaxRush supports practice with these programming languages:

Language Extensions Sample File
Go .go Advanced calculator with structs & methods
Python .py Data processor with classes & statistics
JavaScript .js, .jsx, .ts, .tsx Task manager with ES6+ features
C++ .cpp, .c, .cc Grade system with OOP principles
Java .java Add your own files
Rust .rs Add your own files

๐Ÿ”ง Development

Contributing

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/amazing-feature
  3. Commit changes: git commit -m 'Add amazing feature'
  4. Push to branch: git push origin feature/amazing-feature
  5. Open a Pull Request

Building from Source

# Clone and build
git clone https://github.com/vamshi1188/SyntaxRush.git
cd SyntaxRush
go mod tidy
go build -o syntaxrush

# Run tests
go test ./...

# Run with race detection
go run -race main.go

๐ŸŽฏ Why SyntaxRush?

๐Ÿš€ For Developers

  • Real Code Practice: No more lorem ipsum - practice with actual code
  • Language Agnostic: Works with any programming language
  • Muscle Memory: Build instinctive syntax knowledge
  • Flow State Training: Develop sustained coding rhythm

๐ŸŽฎ For Gamers

  • Achievement System: Unlock progressively harder challenges
  • Power Progression: Build typing endurance like a fitness tracker
  • Visual Feedback: Satisfying real-time progress indicators
  • Competitive Elements: Beat your personal bests

๐Ÿ’ช For Health

  • Fatigue Detection: Prevents typing strain and RSI
  • Break Reminders: Promotes healthy practice habits
  • Stamina Building: Gradual endurance improvement
  • Rhythm Training: Develops consistent, sustainable pace

๐Ÿ“œ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿ™ Acknowledgments

  • Charm - For the amazing Bubble Tea and Lip Gloss libraries
  • Hajimehoshi - For the Oto audio library
  • Go Community - For excellent tooling and ecosystem
  • Contributors - Thank you for making SyntaxRush better!

๐Ÿš€ Ready to become a typing master?

Download SyntaxRush โ€ข Report Bug โ€ข Request Feature

Built with ๐Ÿ’ช for developers who want to type like pros

About

terminal-based code typing trainer for developers

Resources

License

Contributing

Stars

Watchers

Forks

Sponsor this project

 

Packages

No packages published