kaze 2.0.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 858087e59b76bb15ec6cc06701b2ba201c4aacb12cf592cdfbc37f1304b805c1
4
- data.tar.gz: ed23682c9b61226b8201240b0b43e41a660f1745d986c2f4e1b6644aa4d26003
3
+ metadata.gz: e59ed35aebe912f3109e4cf1937daa83a61d11235e2052d4d148c4d67f29fd52
4
+ data.tar.gz: 0c5844feaa1dd744199e50af4aecbb0f53ca8f5ea2a6060b6362b124f16a8762
5
5
  SHA512:
6
- metadata.gz: 888b37a89b65ee26046232a7f9dffcbe028500726c7082911ed74eea0dd4fe27f78d640661e6847d2ace7921544dfe8df67b4c28688ef6dfb00f3f7b140094a8
7
- data.tar.gz: db51173dd6dc0e73686a13df9e4bc0af2afdb50fdde496c43c98860e818d64a0171b9d50142b1d824aa8a89bec4a77657642cc80edbfe072f0274a01436ec736
6
+ metadata.gz: a02c56cd8f4e53405776b9d1240b54b5fe6b6a71f01339a90fe83a04f0864ebef3f68a8d5a6f41e2a80ae9b3d4d70ce376c4a165ec4c38d9354bfe874b969d66
7
+ data.tar.gz: 512b952e164d688a07204f3d3137b39215b5753bdeab6a01543562d3a9156960d0e383ffdd0798270aa75440187fcaa939d756bab7c6316637ac8d00d71cfa52
data/CHANGELOG.md CHANGED
@@ -6,6 +6,14 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [2.0.1] - 2026-10-22
10
+
11
+ ### Fixed
12
+
13
+ - `kaze install` run through `bundle exec` no longer fails to build gems with native extensions. Bundler exports `RUBYOPT` and `BUNDLE_*` so child processes join its bundle, which is wrong for a nested bundler call: the `bundle add` that kaze shells out to inherited them, and `extconf.rb` then loaded `bundler/setup` and tried to resolve a lockfile needing the very gem it was about to compile, failing with `Could not find bcrypt-… in locally installed gems`. The bundler shell-outs now run inside `Bundler.with_unbundled_env`.
14
+
15
+ The README's own instructions — `gem install kaze` then `kaze install` — were never affected, because that runs outside bundler. This reached `bundle exec kaze install`, which is how kaze's CI invokes it and how anyone who adds kaze to their Gemfile would.
16
+
9
17
  ## [2.0.0] - 2026-10-22
10
18
 
11
19
  ### Added
@@ -177,7 +185,8 @@ Together these take a freshly scaffolded Inertia application from seven npm advi
177
185
 
178
186
  Releases before 1.0.0 are not catalogued here. See the [tags](https://github.com/cuonggt/kaze/tags) for their history.
179
187
 
180
- [Unreleased]: https://github.com/cuonggt/kaze/compare/v2.0.0...HEAD
188
+ [Unreleased]: https://github.com/cuonggt/kaze/compare/v2.0.1...HEAD
189
+ [2.0.1]: https://github.com/cuonggt/kaze/compare/v2.0.0...v2.0.1
181
190
  [2.0.0]: https://github.com/cuonggt/kaze/compare/v1.4.0...v2.0.0
182
191
  [1.4.0]: https://github.com/cuonggt/kaze/compare/v1.3.1...v1.4.0
183
192
  [1.3.1]: https://github.com/cuonggt/kaze/compare/v1.3.0...v1.3.1
@@ -13,6 +13,16 @@ class Kaze::Commands::App::BaseStack
13
13
  @bundle_command ||= File.exist?("#{Dir.pwd}/bin/bundle") ? "#{Dir.pwd}/bin/bundle" : 'bundle'
14
14
  end
15
15
 
16
+ # Bundler exports RUBYOPT and BUNDLE_* so that child processes join its
17
+ # bundle. That is wrong for a nested bundler call: when kaze itself is run
18
+ # through `bundle exec`, a `bundle add` it shells out to inherits them, and
19
+ # any gem with a native extension fails to build, because extconf.rb loads
20
+ # bundler/setup and tries to resolve a lockfile needing the very gem it is
21
+ # about to compile. Shell out to bundler with that environment removed.
22
+ def run_bundle_command(command)
23
+ Bundler.with_unbundled_env { run_command(command) }
24
+ end
25
+
16
26
  def install_gems(gems = [], group = nil)
17
27
  installed_gems = Bundler::Definition.build("#{Dir.pwd}/Gemfile", nil, {}).dependencies.map(&:name)
18
28
 
@@ -20,7 +30,7 @@ class Kaze::Commands::App::BaseStack
20
30
 
21
31
  return true if gem_being_installed.empty?
22
32
 
23
- status = run_command("#{bundle_command} add #{gem_being_installed.join(" ")}#{group ? " --group \"#{group}\"" : ""}")
33
+ status = run_bundle_command("#{bundle_command} add #{gem_being_installed.join(" ")}#{group ? " --group \"#{group}\"" : ""}")
24
34
 
25
35
  status.success?
26
36
  end
@@ -32,7 +42,7 @@ class Kaze::Commands::App::BaseStack
32
42
 
33
43
  return true if gems_being_removed.empty?
34
44
 
35
- status = run_command("#{bundle_command} remove #{gems_being_removed.join(" ")}")
45
+ status = run_bundle_command("#{bundle_command} remove #{gems_being_removed.join(" ")}")
36
46
 
37
47
  status.success?
38
48
  end
@@ -3,7 +3,7 @@ class Kaze::Commands::App::HotwireStack < Kaze::Commands::App::BaseStack
3
3
  # Gems...
4
4
  return unless remove_gems([ 'sprockets-rails', 'stimulus-rails' ])
5
5
  return unless install_gems([ 'propshaft', 'view_component', 'turbo-rails', 'dotenv', 'bcrypt' ])
6
- return unless run_command("#{bundle_command} add tailwindcss-rails --version=\"~> 4.0\"").success?
6
+ return unless run_bundle_command("#{bundle_command} add tailwindcss-rails --version=\"~> 4.0\"").success?
7
7
  return unless install_gems([ 'hotwire-livereload' ], 'development')
8
8
  return unless install_gems([ 'factory_bot_rails', 'faker' ], 'development, test')
9
9
 
@@ -3,7 +3,7 @@ class Kaze::Commands::App::InertiaReactStack < Kaze::Commands::App::BaseStack
3
3
  # Gems...
4
4
  return unless remove_gems([ 'sprockets-rails', 'turbo-rails', 'stimulus-rails' ])
5
5
  return unless install_gems([ 'propshaft', 'inertia_rails', 'vite_rails', 'dotenv', 'bcrypt', 'js-routes' ])
6
- return unless run_command("#{bundle_command} add tailwindcss-rails --version=\"~> 4.0\"").success?
6
+ return unless run_bundle_command("#{bundle_command} add tailwindcss-rails --version=\"~> 4.0\"").success?
7
7
  return unless install_gems([ 'factory_bot_rails', 'faker' ], 'development, test')
8
8
 
9
9
  # NPM Packages...
@@ -3,7 +3,7 @@ class Kaze::Commands::App::InertiaVueStack < Kaze::Commands::App::BaseStack
3
3
  # Gems...
4
4
  return unless remove_gems([ 'sprockets-rails', 'turbo-rails', 'stimulus-rails' ])
5
5
  return unless install_gems([ 'propshaft', 'inertia_rails', 'vite_rails', 'dotenv', 'bcrypt', 'js-routes' ])
6
- return unless run_command("#{bundle_command} add tailwindcss-rails --version=\"~> 4.0\"").success?
6
+ return unless run_bundle_command("#{bundle_command} add tailwindcss-rails --version=\"~> 4.0\"").success?
7
7
  return unless install_gems([ 'factory_bot_rails', 'faker' ], 'development, test')
8
8
 
9
9
  # NPM Packages...
data/lib/kaze/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Kaze
2
- VERSION = '2.0.0'
2
+ VERSION = '2.0.1'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kaze
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cuong Giang