rad~$

Getting Started with Rad

This guide will help you get started with Rad, the extremely fast dependency manager for Ruby projects.

Installation

Let's begin by installing Rad on your system. Choose the method that works best for your platform:

terminal
curl -LsSf https://radgems.dev/rad/install.sh | sh
Downloading Rad installer...
Installing Rad v0.1.0...
✓ Rad has been installed successfully!
Run 'rad --help' to get started.

Verifying Installation

Let's make sure Rad is properly installed by checking the version:

terminal
rad version
📦 Rad version: 0.1.0
🚀 The modern dependency manager for Ruby

Available Commands

Let's check the Rad command help to see available options:

terminal
rad --help
📦 Rad version: 0.1.0
⚡ Usage:
• rad [OPTIONS] [COMMAND]
🔍 Commands:
• install Install gems from the lockfile
• update Update dependencies to newer versions
• exec Execute a command in the context of the current bundle
• lock Create or display the Gemfile.lock
• env Display environment information
• config Manage rad configuration
• version Show rad version
• platform Platform compatibility commands
• check Check gem compatibility
• visualize Visualize dependency graph
💡 For more information on a command, run:
• rad COMMAND --help
Rad works with existing Ruby projects and can replace or work alongside Bundler. It fully supports standard Gemfile syntax.

Basic Workflow

Installing Dependencies

To install the dependencies specified in your Gemfile:

terminal
rad install
✨ RAD INSTALL ✨
📦 Installing gems with default groups
🔄 Initializing installation...
Installation path: vendor/bundle
Platform: darwin-arm64 (compatible with: darwin-arm64, ruby, macos-arm64)
📦 Processing gems...
• Processing gem: noticed
✓ [✓] Using noticed v0.1.0
• Processing gem: rails
✓ [✓] Using rails v7.0.6
• Processing gem: sqlite3
🔷 [✓] Using sqlite3 v2.6.0
• Processing gem: rack
✓ [✓] Using rack v3.1.13
• Processing gem: googleauth
🔒 [✓] Using googleauth v1.1.3
Creating binary stubs...
• 🔨 Creating executable stubs No binary stubs created
✨ INSTALLATION COMPLETE! ✨
📊 Summary: 0 gems installed, 9 gems already present
📦 9 gems ready to use in 0.08s
💡 Pro Tip: Run 'rad exec ruby your_script.rb' to use these gems in your Ruby scripts
Rad is 3-8x faster than Bundler for cold cache operations. With a large project (45+ gems), Rad completes installation in about 6.3 seconds compared to Bundler's 52.4 seconds.

Adding a New Dependency

To add a new gem to your project:

terminal
rad add rails
💎 RAD ADD 💎
🧩 Adding gem: rails
✅ Successfully added gem: rails
📌 Version: latest
📋 Updating lockfile...
⚙️ Resolving dependencies...
🔍 Analyzing gem compatibility
✅ Gemfile.lock updated

Removing a Dependency

terminal
rad delete rails
💎 RAD DELETE 💎
🗑️ Removing gem: rails
✅ Successfully removed gem: rails
📋 Updating lockfile...
⚙️ Resolving dependencies...
🔍 Analyzing gem compatibility
✅ Gemfile.lock updated

Updating Dependencies

terminal
rad update
📦 Updating gems in all groups
Fetching gem metadata from https://rubygems.org/...
Resolving dependencies...
🔄 Outdated gems in your project:
• rails 7.0.6 -> 7.1.0
• activesupport 7.0.6 -> 7.1.0
• activerecord 7.0.6 -> 7.1.0
• ...
🔄 Installing updates...
• Updating rails to 7.1.0
• Updating activesupport to 7.1.0
• ...
✅ Updated 12 gems in 0.64 seconds

Running Commands in the Context of Your Project

Use rad exec to run commands with access to your project's gem environment:

terminal
rad exec rails server
📦 Running via Rad Exec (0.1.0)
=> Booting Puma
=> Rails 7.1.0 application starting in development
=> Run `bin/rails server --help` for more startup options
Puma starting in single mode...
* Listening on http://127.0.0.1:3000
Use Ctrl-C to stop

rad exec provides a fast runtime environment for your commands with all dependencies properly configured. This makes it perfect for running your test suites, Rails commands, and other gem executables.

Configuration

Rad stores its configuration in .rad/config.toml:

terminal
cat .rad/config.toml
# Rad configuration file
[global]
default_platform = "ruby"
parallel_jobs = 8
color_output = true
[network]
retry_count = 3
timeout_seconds = 30
allow_insecure = false
[cache]
path = "vendor/cache"
expiry_days = 30
[mirror]
primary = "https://rubygems.org"
fallbacks = []
[platform]
auto_detect = true
enabled = ["ruby", "x86_64-darwin-22"]

You can update configuration values using the rad config command:

terminal
rad config set cache.path vendor/rad-cache
Updated configuration:
cache.path = "vendor/rad-cache" (was "vendor/cache")

Next Steps

Now that you have Rad installed and know the basics, here are some resources to explore next:

Need help?

If you encounter any issues, open an issue on GitHub.

GitHub