Skip to content

Latest commit

 

History

History
157 lines (121 loc) · 3.87 KB

File metadata and controls

157 lines (121 loc) · 3.87 KB

Usage Guide

Quick Start

  1. Navigate to any code repository:

    cd /path/to/your/project
  2. Start typing practice (uses current directory by default):

    gittype
  3. Or specify a specific repository:

    gittype /path/to/another/repo
  4. Or clone and use a GitHub repository:

    gittype --repo unhappychoice/gittype
  5. Play with cached repositories interactively:

    gittype repo play
  6. Discover trending repositories:

    gittype trending
    gittype trending rust

Command Line Options

gittype [OPTIONS] [REPO_PATH] [COMMAND]

Note: REPO_PATH is optional and defaults to the current directory (.) if not specified.

Basic Options

Option Description Default
--repo GitHub repository URL or path to clone and use None
--langs Filter by programming languages (comma-separated) All supported
--config Path to a custom configuration file None

Examples

# Practice with Rust and TypeScript files only
gittype --langs rust,typescript

Custom Excludes with .gittypeignore

If your repository vendors third-party code, create a .gittypeignore file at the repository root. Each non-empty line is parsed with .gitignore-style syntax (comments, rooted paths like /vendor/, etc.).

# Example .gittypeignore
/vendor/
**/third_party/**

Commands

View Session History

gittype history

Show session history.

Show Analytics

gittype stats

Show analytics.

Export Session Data

gittype export [OPTIONS]

Export session data.

Option Description Default
--format Export format json
--output Output file path stdout

Example:

# Export history to a JSON file
gittype export --output history.json

Manage Challenge Cache

gittype cache <COMMAND>

Cache Commands:

  • gittype cache stats - Show cache statistics
  • gittype cache clear - Clear all cached challenges
  • gittype cache list - List cached repository keys

Manage Repositories

gittype repo <COMMAND>

Repository Commands:

  • gittype repo list - List all cached repositories
  • gittype repo clear [--force] - Clear all cached repositories
  • gittype repo play - Play a cached repository interactively

Practice with Trending Repositories

gittype trending [LANGUAGE] [OPTIONS]

Discover and practice typing with trending GitHub repositories. Repositories are cached and updated automatically.

Options:

Option Description Default
LANGUAGE Programming language to filter repositories All languages
--period Time period for trending (daily, weekly, monthly) daily

Supported Languages:

  • C, C#, C++, Dart, Elixir, Erlang, Go, Haskell, Java, JavaScript, Kotlin, PHP, Python, Ruby, Rust, Scala, Swift, TypeScript, Zig

Examples:

# Browse trending repositories interactively (all languages)
gittype trending

# Show trending Rust repositories for interactive selection
gittype trending rust

# Show weekly trending Python repositories
gittype trending python --period weekly

# Show monthly trending repositories for all languages
gittype trending --period monthly

How it works:

  1. Interactive Selection: When no specific repository is provided, GitType shows an interactive list of trending repositories
  2. Language Filtering: Specify a language to see only repositories in that programming language
  3. Direct Repository Selection: Provide a repository name to search for and play with that specific repository
  4. Automatic Caching: Trending data is cached to reduce API calls and improve performance
  5. Seamless Integration: Selected repositories are automatically cloned and ready for typing practice