$ account ruby
This is the official reference implementation of the Ruby programming language (CRuby/MRI). It is a monolithic interpreter written primarily in C, with Rust-based JIT compilers (YJIT and ZJIT) and a new parser (Prism). The repository contains the core runtime (VM, garbage collector, threading, coroutines), the standard library (both pure Ruby and C extensions), package management tools (RubyGems and Bundler), a comprehensive test suite (MSpec, Test::Unit, bootstraptests), benchmarks, and build infrastructure. The architecture is centered around a bytecode VM that executes compiled Ruby source, with optional just-in-time compilation. Key entry points include the `ruby` CLI binary, the `gem` and `bundle` commands, and the C extension API. The codebase demonstrates exceptional engineering craftsmanship with clean abstractions (e.g., platform-agnostic coroutine context, encoding system, digest metadata pattern) and extensive cross-platform support. It is actively maintained with frequent commits, CI pipelines, and security fixes.
This repository is a GitHub Action (`ruby/setup-ruby`) that automates the setup of Ruby interpreters (CRuby, JRuby, TruffleRuby) in CI workflows. It downloads prebuilt binaries from official builders (ruby-builder, RubyInstaller2), adds them to PATH, and optionally configures RubyGems and Bundler with intelligent version resolution. A key feature is built-in caching of `bundle install` results via a sophisticated key scheme that accounts for OS, Ruby version, Bundler configuration, and gemfile lock hash. The action supports reading Ruby version from `.ruby-version`, `.tool-versions`, or `mise.toml`, and handles Windows toolchains (MSYS2, DevKit, VCPKG/MSVC) for native gem compilation. The architecture is modular (common utilities, Ruby builder, Bundler, RubyGems, Windows-specific code) and the code is well-structured with clear error handling and thorough CI testing across a matrix of 100+ combinations of OS, Ruby versions, and architectures. Maintenance is active with automated version updates via scheduled workflows and a defined release team.