Skip to content

Add .claude skills + workspace scripts from rails_template, update Ruby 4.0.6 + gems - #133

Merged
sethherr merged 7 commits into
mainfrom
sethherr/pull-claude-files-from-rails-template
Jul 28, 2026
Merged

Add .claude skills + workspace scripts from rails_template, update Ruby 4.0.6 + gems#133
sethherr merged 7 commits into
mainfrom
sethherr/pull-claude-files-from-rails-template

Conversation

@sethherr

@sethherr sethherr commented Jul 28, 2026

Copy link
Copy Markdown
Member

Pulls the .claude tree and the workspace scripts from sethherr/rails_template into this app, and bumps Ruby + all gems.

  • Adds 8 skills (pr, frontend-screenshots, github-upload-image-to-pr, frontend-conventions, rspec-testing, integration-testing, merge-conflicts, sandbox-test-setup), the /pr command, and a .mcp.json registering the playwright MCP server. Each skill was verified against this codebase — the template's seeded users, Form::Combobox, amount_display, site footer, and spec/integration/ don't exist here, so those sections were corrected or dropped.
  • Ports bin/env, bin/setup, bin/workspace_setup, bin/workspace_teardown, and bin/char_count (+ the bin/dev change that uses them). bin/workspace_setup claims an ID from a machine-wide dev_workspaces registry; bin/env turns it into DEV_PORT/BASE_URL/REDIS_URL and database.yml suffixes the databases with it, so each checkout gets its own port, postgres databases, and redis database. bin/workspace_teardown replaces bin/conductor_teardown and also releases the ID.
  • Migration note: database.yml moves from the CONDUCTOR_WORKSPACE_NAME suffix to the workspace ID, and the CONDUCTOR_PORT fallback is gone (the root checkout falls back to port 3009). Existing workspaces need to re-run bin/workspace_setup; their _<name>-suffixed databases are orphaned until they do.
  • Ruby 4.0.2 → 4.0.6 plus a full bundle update: 27 major gem bumps, 71 minor/patch. Bundler 2.7.2 → 4.0.17 is the default shipped with Ruby 4.0.6. hotwire-livereload 1.2 → 2.1 dropped the hotwire_livereload_tags view helper in favor of a Rack middleware that injects the script itself, so the layout call raised on every dev page — removed it.
  • Adds the debug gem, which was never a dependency: Bundler excluded it, so bin/dev's RUBY_DEBUG_OPEN/RUBY_DEBUG_LAZY exports did nothing and debugger raised. Also re-enables lib/tasks/parallel_migrate, now behind an opt-in PARALLEL_MIGRATIONS gate rather than on by default.

sethherr and others added 3 commits July 28, 2026 09:29
Pull the `.claude` tree from sethherr/rails_template and adapt each skill
to this app: pr (+ /pr command), frontend-screenshots,
github-upload-image-to-pr, frontend-conventions, rspec-testing,
integration-testing, merge-conflicts, and sandbox-test-setup. Every
concrete claim was verified against this codebase — the template's
seeded users, `Form::Combobox`, `amount_display`, site footer, and
`spec/integration/` don't exist here, so those sections were corrected
or removed.

Also register the playwright MCP server via .mcp.json, and narrow the
.gitignore entry from `.claude/*` to `.claude/settings.local.json` so
the skills are actually tracked.

Co-Authored-By: Claude <noreply@anthropic.com>
Bumps Ruby 4.0.2 -> 4.0.6 and refreshes the lockfile: 27 major gem
bumps, 71 minor/patch. Bundler moves 2.7.2 -> 4.0.17, which is the
default shipped with Ruby 4.0.6.

Two fixes the update required:

- hotwire-livereload 1.2 -> 2.1 dropped the `hotwire_livereload_tags`
  view helper in favor of a Rack middleware that injects the script
  automatically, so the layout call now raises. Removed it. This only
  affected development, so no spec covered it.
- standard 1.54 -> 1.56 flags `Style/RedundantParentheses` in the admin
  topic_reviews request spec.

Co-Authored-By: Claude <noreply@anthropic.com>
Ports bin/env, bin/setup, bin/workspace_setup, and bin/workspace_teardown
from sethherr/rails_template, plus the bin/dev change that uses them.

bin/workspace_setup claims the next free ID from a local `dev_workspaces`
postgres database, writes it to .workspace_id, and execs bin/setup. bin/env
turns that ID into DEV_PORT, BASE_URL, and REDIS_URL, and database.yml
suffixes the databases with it, so each checkout gets its own port, postgres
databases, and redis database. The ID pool is machine-wide, so workspaces
across projects can't collide on a port either.

Replaces bin/conductor_teardown with bin/workspace_teardown, which also stops
bin/dev and releases the ID for reuse. It drops only databases whose names end
in `_<id>`, so the shared un-suffixed ones are never at risk.

database.yml switches from the CONDUCTOR_WORKSPACE_NAME suffix to the
workspace ID. Existing workspaces keep working via bin/env's CONDUCTOR_PORT
fallback, but their old `_<name>`-suffixed databases are orphaned until they
re-run bin/workspace_setup.

bin/setup also gains the template's ruby-version check via mise, a
node_modules symlink, a JS dependency install (yarn, not the template's npm),
and --without_seeds.

Co-Authored-By: Claude <noreply@anthropic.com>
@sethherr sethherr changed the title Add .claude skills from rails_template, update Ruby 4.0.6 + all gems Add .claude skills + workspace scripts from rails_template, update Ruby 4.0.6 + gems Jul 28, 2026
sethherr and others added 4 commits July 28, 2026 09:42
The `connection_pool < 3` pin was marked temporary; sidekiq 8.1 requires
connection_pool >= 3.0, so the pin was what held sidekiq at 8.0.10.

- connection_pool 2.5.5 -> 3.0.2
- listen 3.0.8 -> 3.10.0
- sidekiq 8.0.10 -> 8.1.6

mustermann and diff-lcs are unchanged: sinatra 4.2.1 (latest) requires
mustermann ~> 3.0, and rspec-expectations 3.13.5 (latest) plus super_diff
0.19.0 (latest) both cap diff-lcs below 2.0. Neither can move until those
gems release.

Co-Authored-By: Claude <noreply@anthropic.com>
Matches rails_template's structure (a bare literal) with convus's own port.
3009 is what config/environments/development.rb and README.md already
document, and what bin/env used before the workspace scripts landed.

Conductor workspaces get their port from .workspace_id via
bin/workspace_setup, so the CONDUCTOR_PORT lookup was redundant — the
fallback now only applies to the root checkout, which should be 3009.

Co-Authored-By: Claude <noreply@anthropic.com>
bin/workspace_teardown only matched TEST_ENV_NUMBER 1-8, but
parallel:prepare creates one test DB per core (14 on this machine), so
`_<id>9` through `_<id>14` were left behind on every teardown — visible
in the local cluster as orphaned bikebook_app_test_307310..._307314 with
their 2-8 siblings already dropped. Since bin/workspace_setup recycles
IDs after DELETED_REUSE_DELAY, a reused ID inherited those stale DBs.
Widened to [0-9]*.

bin/dev's RUBY_DEBUG_OPEN/RUBY_DEBUG_LAZY exports were inert: debug is a
bundled gem, not a Gemfile entry, so Bundler excluded it and every
Procfile.dev process (all under bundle exec) raised LoadError on
`require "debug"`. Added it to the :development group with
require: "debug/prelude" rather than a plain require — debug.rb only
loads the prelude when RUBY_DEBUG_LAZY is set, so a plain require would
eagerly start a session in dev processes not launched by bin/dev.

Two skills declared allowed-tools that excluded the Playwright MCP tools
their bodies are built around, so they could not reach them:
frontend-screenshots (Bash, Read) and github-upload-image-to-pr, whose
Bash(gh:*)/Bash(cp:*) also blocked its temp-file write step.

frontend-conventions used helpers.time_ago_in_words as the `helpers.`
prefix example, which the same file bans in favor of UI::Time::Component.
Swapped in helpers.current_page_active?, used that way in
app/components/navbar/component.html.erb. Not number_display —
ApplicationComponent includes ApplicationComponentHelper, so that one
works bare and would contradict the following line's rule of thumb.

Also restores bin/char_count from rails_template (dropped from agents.md
because the script was missing) and uncomments lib/tasks/parallel_migrate
as an opt-in PARALLEL_MIGRATIONS gate.

Co-Authored-By: Claude <noreply@anthropic.com>
The parallel_migrate gate is now opt-in `PARALLEL_MIGRATIONS`, so CI's
`SKIP_PARALLEL_MIGRATIONS: true` no longer reads as anything — the task
is off by default, which is what CI wanted. No tracked file references
the old name now.

The db:schema:dump comment referenced an enhancement this repo doesn't
have (only that comment matched `schema:dump` under lib/tasks and
config), so it was carried over from elsewhere.

Co-Authored-By: Claude <noreply@anthropic.com>
@sethherr
sethherr marked this pull request as ready for review July 28, 2026 19:37
@sethherr
sethherr merged commit 1af9cde into main Jul 28, 2026
2 checks passed
@sethherr
sethherr deleted the sethherr/pull-claude-files-from-rails-template branch July 28, 2026 19:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant