/principles:setup-rubyfrom principles
Installs Ruby 3.4 via rbenv and ruby-build when the `principles` command fails due to an unsupported Ruby version. Asks before installing.
Ships in principles. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description, though model invocation is off: only you can start it.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
principles runs on Ruby 3.4, from 3.4.2 up to but not including 3.5. When the Ruby on the PATH is another
version, principles looks for a Ruby 3.4 that rbenv installed, in $RBENV_ROOT or ~/.rbenv, and runs itself
on that. So this setup installs one Ruby 3.4 with rbenv and changes nothing else. It sets no global Ruby and
does not touch the user's shell profile.
Run principles --version. If it prints a version, Ruby is already set up: stop here and say so.
Otherwise, find out what is already installed:
command -v brew; command -v rbenv; ls "${RBENV_ROOT:-$HOME/.rbenv}/versions" 2>/dev/null
Ask the user to approve installation, showing the exact commands you will run and what each one installs.
Leave out a step whose tool is already installed. Installing needs the network, and it writes outside the
project, under Homebrew's prefix and ~/.rbenv. If your sandbox refuses either, give the user the commands
to run themselves, each typed after ! so its output lands in this session.
On macOS with Homebrew:
brew install rbenv ruby-build
rbenv install --list | grep -E '^3\.4\.[0-9]+$' | tail -1 # the newest Ruby 3.4
rbenv install 3.4.N # N from the line above
On Linux, or without Homebrew, first install the build dependencies that ruby-build's wiki lists for the system, then:
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
git clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-build
~/.rbenv/bin/rbenv install --list | grep -E '^3\.4\.[0-9]+$' | tail -1
~/.rbenv/bin/rbenv install 3.4.N
Run nothing until the user says yes.
Run principles --version again. It should print a version from any directory. If it still refuses, show the
user its message, which names the Ruby that ran and what was looked for.
Tell the user exactly what you installed and where, and how to remove each piece:
rbenv uninstall 3.4.Nbrew uninstall ruby-build rbenvrm -rf ~/.rbenv, after checking it holds no other Ruby the user
wants to keepWhat SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub realfastai/principles --plugin principles2 skills in this plugin
Other plugins' skills for the same job