kaze 1.0.0 → 1.1.0

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: 9138221bd4a2ceb298c1663380c4b20ea389ae6d140be70e8e5566fcd8c9d37f
4
- data.tar.gz: 0b7ef58519530ffe3210a5f427451266788b82259ec18481a6f2a3a5aa7e0410
3
+ metadata.gz: a1a94f3dd3de84493b3cbc6acf9e7e1fd337b93cb67b87aad2d97c60e7b064f7
4
+ data.tar.gz: 80d6c19bbb883bfe8dccee90772dbb67a02d9342732b01a9f9c98a2518a494bd
5
5
  SHA512:
6
- metadata.gz: 65894c1042fa1b3af7cb836a75af0a2eb5115701bafa4ad8a911c6be363341e58aa910776cb61c0fdec5deb2cbef09ec0d8fc5a4c32a8ddd25d6d816c3d60677
7
- data.tar.gz: afe217578c1e3cb6122b07cfac695b2217eeda27161a99d6cca2c2131ab5a6c72f472558949031b0916189b8895b81b0748c3186f62e9e51db6b6bb7877f98c0
6
+ metadata.gz: b78d27e32275e9992afca59c84c67fba216febaca0dd5183e816027b5f83fcdba4ea3deccb6fb5bf9c1d5cd484e917b739efb9f50b8a261491a09f2efe05bc60
7
+ data.tar.gz: fed091fb475690ca39181e0b1ac26912edf0206f776e3f7f1cdade0d51b8732ab497984cb9e0d9bf74330aba6bae32e712d1e9ba85407d41460e523172571aa9
@@ -9,6 +9,10 @@ class Kaze::Commands::App::BaseStack
9
9
 
10
10
  private
11
11
 
12
+ def bundle_command
13
+ @bundle_command ||= File.exist?("#{Dir.pwd}/bin/bundle") ? "#{Dir.pwd}/bin/bundle" : "bundle"
14
+ end
15
+
12
16
  def install_gems(gems = [], group = nil)
13
17
  installed_gems = Bundler::Definition.build("#{Dir.pwd}/Gemfile", nil, {}).dependencies.map(&:name)
14
18
 
@@ -16,7 +20,7 @@ class Kaze::Commands::App::BaseStack
16
20
 
17
21
  return true if gem_being_installed.empty?
18
22
 
19
- status = run_command("#{Dir.pwd}/bin/bundle add #{gem_being_installed.join(" ")}#{group ? " --group \"#{group}\"" : ""}")
23
+ status = run_command("#{bundle_command} add #{gem_being_installed.join(" ")}#{group ? " --group \"#{group}\"" : ""}")
20
24
 
21
25
  status.success?
22
26
  end
@@ -28,7 +32,7 @@ class Kaze::Commands::App::BaseStack
28
32
 
29
33
  return true if gems_being_removed.empty?
30
34
 
31
- status = run_command("#{Dir.pwd}/bin/bundle remove #{gems_being_removed.join(" ")}")
35
+ status = run_command("#{bundle_command} remove #{gems_being_removed.join(" ")}")
32
36
 
33
37
  status.success?
34
38
  end
@@ -70,7 +70,7 @@ class Kaze::Commands::App::InertiaReactStack < Kaze::Commands::App::BaseStack
70
70
  run_commands([ 'pnpm install', 'pnpm run build' ])
71
71
  elsif File.exist?("#{Dir.pwd}/yarn.lock")
72
72
  run_commands([ 'yarn install', 'yarn build' ])
73
- elsif File.exist?("#{Dir.pwd}/bun.lockb")
73
+ elsif File.exist?("#{Dir.pwd}/bun.lock") || File.exist?("#{Dir.pwd}/bun.lockb")
74
74
  run_commands([ 'bun install', 'bun run build' ])
75
75
  else
76
76
  run_commands([ 'npm install', 'npm run build' ])
@@ -70,7 +70,7 @@ class Kaze::Commands::App::InertiaVueStack < Kaze::Commands::App::BaseStack
70
70
  run_commands([ 'pnpm install', 'pnpm run build' ])
71
71
  elsif File.exist?("#{Dir.pwd}/yarn.lock")
72
72
  run_commands([ 'yarn install', 'yarn build' ])
73
- elsif File.exist?("#{Dir.pwd}/bun.lockb")
73
+ elsif File.exist?("#{Dir.pwd}/bun.lock") || File.exist?("#{Dir.pwd}/bun.lockb")
74
74
  run_commands([ 'bun install', 'bun run build' ])
75
75
  else
76
76
  run_commands([ 'npm install', 'npm run build' ])
data/lib/kaze/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Kaze
2
- VERSION = '1.0.0'
2
+ VERSION = '1.1.0'
3
3
  end
@@ -6,10 +6,9 @@
6
6
  <title><%= content_for(:title) || "Rails" %></title>
7
7
  <%= csrf_meta_tags %>
8
8
  <%= csp_meta_tag %>
9
- <%= stylesheet_link_tag "tailwind", "inter-font", "data-turbo-track": "reload" %>
10
- <%= stylesheet_link_tag "application", "data-turbo-track": "reload" %>
9
+ <%= stylesheet_link_tag "tailwind", "inter-font", "data-turbo-track": Rails.env.production? ? "reload" : "" %>
10
+ <%= stylesheet_link_tag "application", "data-turbo-track": Rails.env.production? ? "reload" : "" %>
11
11
  <%= javascript_importmap_tags %>
12
- <%= hotwire_livereload_tags if Rails.env.development? %>
13
12
  <%= turbo_refreshes_with method: :morph, scroll: :preserve %>
14
13
  <%= yield :head %>
15
14
  </head>
@@ -6,10 +6,9 @@
6
6
  <title><%= content_for(:title) || "Rails" %></title>
7
7
  <%= csrf_meta_tags %>
8
8
  <%= csp_meta_tag %>
9
- <%= stylesheet_link_tag "tailwind", "inter-font", "data-turbo-track": "reload" %>
10
- <%= stylesheet_link_tag "application", "data-turbo-track": "reload" %>
9
+ <%= stylesheet_link_tag "tailwind", "inter-font", "data-turbo-track": Rails.env.production? ? "reload" : "" %>
10
+ <%= stylesheet_link_tag "application", "data-turbo-track": Rails.env.production? ? "reload" : "" %>
11
11
  <%= javascript_importmap_tags %>
12
- <%= hotwire_livereload_tags if Rails.env.development? %>
13
12
  <%= turbo_refreshes_with method: :morph, scroll: :preserve %>
14
13
  </head>
15
14
  <body class="font-sans text-gray-900 antialiased">
@@ -6,10 +6,9 @@
6
6
  <title><%= content_for(:title) || "Rails" %></title>
7
7
  <%= csrf_meta_tags %>
8
8
  <%= csp_meta_tag %>
9
- <%= stylesheet_link_tag "tailwind", "inter-font", "data-turbo-track": "reload" %>
10
- <%= stylesheet_link_tag "application", "data-turbo-track": "reload" %>
9
+ <%= stylesheet_link_tag "tailwind", "inter-font", "data-turbo-track": Rails.env.production? ? "reload" : "" %>
10
+ <%= stylesheet_link_tag "application", "data-turbo-track": Rails.env.production? ? "reload" : "" %>
11
11
  <%= javascript_importmap_tags %>
12
- <%= hotwire_livereload_tags if Rails.env.development? %>
13
12
  <%= turbo_refreshes_with method: :morph, scroll: :preserve %>
14
13
  </head>
15
14
  <body class="font-sans antialiased">
@@ -65,7 +65,7 @@ export default function Login({ status }: { status?: string }) {
65
65
 
66
66
  <div className="block mt-4">
67
67
  <label className="flex items-center">
68
- <Checkbox name="remember" checked={data.remember} onChange={(e) => setData('remember', e.target.checked)} />
68
+ <Checkbox name="remember" checked={data.remember} onChange={(e) => setData('remember', (e.target.checked || false) as false)} />
69
69
  <span className="ms-2 text-sm text-gray-600 dark:text-gray-400">Remember me</span>
70
70
  </label>
71
71
  </div>
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kaze
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cuong Giang
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2025-02-02 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: thor
@@ -52,7 +51,6 @@ dependencies:
52
51
  - - ">="
53
52
  - !ruby/object:Gem::Version
54
53
  version: '0'
55
- description:
56
54
  email:
57
55
  - thaicuong.giang@gmail.com
58
56
  executables:
@@ -256,7 +254,6 @@ homepage: https://github.com/gtkvn/kaze
256
254
  licenses:
257
255
  - MIT
258
256
  metadata: {}
259
- post_install_message:
260
257
  rdoc_options: []
261
258
  require_paths:
262
259
  - lib
@@ -271,8 +268,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
271
268
  - !ruby/object:Gem::Version
272
269
  version: '0'
273
270
  requirements: []
274
- rubygems_version: 3.5.16
275
- signing_key:
271
+ rubygems_version: 3.6.9
276
272
  specification_version: 4
277
273
  summary: Opinionated minimal Rails authentication scaffolding with Hotwire, React,
278
274
  or Vue + Tailwind.