Changelog
Unreleased
Changed
-
Verify the root, master, and main box model against Ruby 4.0.7 source and clarify initialization, shared objects, loading state, and global boot order.
-
Require Ruby 4.0.7+, RubyGems 4.0.23+, and Bundler 4.0.23+ within 4.x. Pin RubyGems and Bundler to 4.0.23 in CI.
-
Use standard executable lookup in example binstubs and simplify script execution and standalone CLI boot.
-
Load globals in the master box so package boxes inherit global constants, methods, and gems.
-
Use
Ruby::Box.masterdirectly and reserve “global context” for Boxwerk’s shared application configuration, gems, and constants. -
Set up Bundler before loading Boxwerk’s dependencies to respect project lockfiles when newer dependency versions are also installed.
-
bin/setupnow installs gems for the example apps too, so the repository test suite works after a fresh clone.
Fixed
-
Per-package gem load paths contain only the lockfile’s exact versions. Other installed versions of a dependency could come first and win.
-
Docs limit monkey patch isolation to built-in classes and explain that global and dependency classes are shared across packages.
-
The gem ships only the library, executable, and user docs, listed explicitly so it builds without git.
v0.3.0 — 2026-03-02
Complete architecture rewrite. Each package now runs in its own Ruby::Box with constants resolved lazily at runtime via const_missing. Reads standard Packwerk package.yml files without requiring Packwerk.
Added
-
Package isolation — each package runs in its own
Ruby::Box; constants from undeclared dependencies and private constants raiseNameErrorat runtime. -
Per-package gems — packages can declare their own
gems.rb/Gemfilewith independent gem versions; auto-require mirrors Bundler’s default behaviour (respectsrequire: false,require: 'path'). -
Zeitwerk autoloading — constants discovered via Zeitwerk conventions; default autoload roots:
lib/andpublic/. -
Privacy enforcement —
enforce_privacy,public_path,private_constants, and# pack_public: truefile sigil. -
Boxwerk.package— returns aPackageContextin per-packageboot.rbwithname,root?,config,root_path, andautoloader. -
Boxwerk.global— returns aGlobalContextfrom any box context. -
Autoloader API —
push_dir,collapse,ignore,setupon bothPackageContext::AutoloaderandGlobalContext::Autoloader; shared viaAutoloaderMixin.push_dirandcollapseauto-callsetupso constants are available immediately in boot scripts. -
global/boot.rb— runs in the root box before package boxes; shared constants defined here are inherited by all packages. -
eager_load_global/eager_load_packagesboxwerk.yml options. -
Package name normalization — leading
./and trailing/stripped;packs/foo,./packs/foo, andpacks/foo/are equivalent. -
CLI commands —
exec,run,console,install,info. -
boxwerk install— installs gems for all packages; works on a fresh clone without pre-installed gems. -
boxwerk info— shows config, global context, and per-package autoload/collapse/ignore dirs (with eager-load status), enforcements, dependencies, gems, and boot script presence. Boots the application (RUBY_BOX=1required). -
NameError hints — improved error messages like
(defined in 'packs/baz', not a dependency of '.')in child package contexts. -
Circular dependency detection in
boxwerk infotree output. -
collapse/ignorein boot.rb — collapses intermediate namespaces (e.g.Analytics::Formatters→Analytics::*); ignores dirs from autoloading. -
Missing lockfile warning — graceful message directing to
boxwerk installwhen a Gemfile exists but no lockfile is found. -
Monkey patch isolation — patches defined in one package box are not visible in other packages or the root context.
-
examples/complexandexamples/minimaldemonstrating all features. -
E2E test suite (74 tests) alongside unit tests (120 tests).
-
GitHub Pages API documentation published from
lib/via RDoc.
Removed
-
Custom file-to-constant mapping (
Boxwerk.camelize), replaced by Zeitwerk. -
Namespace wrapping.
v0.2.0 — 2026-01-06
Changed
-
Simplified implementation (~370 lines removed)
-
Consolidated cycle detection in Graph (removed redundant methods)
-
Added class-level documentation to all modules
-
Simplified example application
Removed
-
Removed
Gemfile.lockfrom git (library best practice) -
Removed
sig/boxwerk.rbs
v0.1.0 — 2026-01-05
Initial release.