Releases: dtcristo/boxwerk
Releases · dtcristo/boxwerk
Release list
0.3.0
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.
0.2.0
Changed
- Simplified implementation (~370 lines removed)
- Consolidated cycle detection in Graph (removed redundant methods)
- Removed unused Loader methods
- Streamlined all module implementations
- Added class-level documentation to all modules
- Simplified example application
Removed
- Removed
Gemfile.lockfrom git (library best practice) - Removed
sig/boxwerk.rbs - Excluded
example/from gem package
Tests
- Reduced test suite from 62 to 46 tests
- Removed redundant unit tests (275 lines)
- Maintained full integration test coverage