hanami-cli 2.2.0 → 2.2.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: af8c95d39ccda17c32851a787f8ef309b6af8936d1bb1eca4780a8f57969af66
4
- data.tar.gz: a4aff54793a12526acf3919a16657fea36d496645fad596f2d214f3baf00e974
3
+ metadata.gz: f7c2e2213ec21d8e65e4a07b1f5035d082e58ff8e5f0368112aa58b4be53a4f2
4
+ data.tar.gz: 7191dcdef8dd7683ada1caf68fab01c6047c3b9368006ce821d01453b77fb00d
5
5
  SHA512:
6
- metadata.gz: 4a82b7839e9890b5dc3ed61b6e95ba3cc42dc1ba217d8d2f60b77fe2dd09a566331a1164f3ea8236ecb25f303bc64203388c5d1803ae38f0f5bffc18a9d9c60d
7
- data.tar.gz: a3b6a3321bab8c5089c601849e47f159efe839413ac40292042c75f78b1ffd43d976ffc8615ed1ade575aba1e8b8a01fb299ac0cf2265e122cbb509c2dd497f3
6
+ metadata.gz: 7ee16c77ac4c7f721c02678ba7bbe1735ba84f66b41a04c738706ab704600230b58ae573c12a3b460851bffb7177403c7df402f8242afdd35949a670b6c30595
7
+ data.tar.gz: a93f0f48ae108ecdcd0f33812b0c83c09a88e9891c3712edd461c55cba09b3b96df3067828ff3f14cad0bc03e320cb634fc9098fd6777107f4d75b8dfec88c57
data/CHANGELOG.md CHANGED
@@ -2,6 +2,16 @@
2
2
 
3
3
  Hanami Command Line Interface
4
4
 
5
+ ## v2.2.1 - 2024-11-12
6
+
7
+ ### Changed
8
+
9
+ - [Tim Riley] Run a bundle install inside `hanami install`. Combined with first-party extension gems modifying the new app's `Gemfile` via a `before "install"` command hook, this ensures that all necessary gems are installed duringthe `hanami new` command. (#269)
10
+
11
+ ### Fixed
12
+
13
+ - [Tim Riley] Allow `hanami new` to be called with `--skip-db` (#266)
14
+
5
15
  ## v2.2.0 - 2024-11-05
6
16
 
7
17
  ### Changed
@@ -33,9 +33,21 @@ module Hanami
33
33
  # @api private
34
34
  option :head, type: :flag, desc: "Install head deps", default: DEFAULT_HEAD
35
35
 
36
+ # @api private
37
+ private attr_reader :bundler
38
+
39
+ def initialize(
40
+ fs:,
41
+ bundler: CLI::Bundler.new(fs: fs),
42
+ **opts
43
+ )
44
+ @bundler = bundler
45
+ end
46
+
36
47
  # @since 2.0.0
37
48
  # @api private
38
49
  def call(head: DEFAULT_HEAD, **)
50
+ bundler.install!
39
51
  end
40
52
  end
41
53
  end
@@ -126,7 +126,6 @@ module Hanami
126
126
  app = inflector.underscore(app)
127
127
 
128
128
  raise PathAlreadyExistsError.new(app) if fs.exist?(app)
129
- raise ConflictingOptionsError.new("--skip-db", "--database") if skip_db && database
130
129
 
131
130
  normalized_database ||= normalize_database(database)
132
131
 
@@ -144,11 +143,11 @@ module Hanami
144
143
  if skip_install
145
144
  out.puts "Skipping installation, please enter `#{app}' directory and run `bundle exec hanami install'"
146
145
  else
147
- out.puts "Running Bundler install..."
146
+ out.puts "Running bundle install..."
148
147
  bundler.install!
149
148
 
150
149
  unless skip_assets
151
- out.puts "Running NPM install..."
150
+ out.puts "Running npm install..."
152
151
  system_call.call("npm", ["install"]).tap do |result|
153
152
  unless result.successful?
154
153
  puts "NPM ERROR:"
@@ -157,7 +156,7 @@ module Hanami
157
156
  end
158
157
  end
159
158
 
160
- out.puts "Running Hanami install..."
159
+ out.puts "Running hanami install..."
161
160
  run_install_command!(head: head)
162
161
  end
163
162
  end
@@ -6,6 +6,6 @@ module Hanami
6
6
  #
7
7
  # @api public
8
8
  # @since 2.0.0
9
- VERSION = "2.2.0"
9
+ VERSION = "2.2.1"
10
10
  end
11
11
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hanami-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.0
4
+ version: 2.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Luca Guidi
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-11-05 00:00:00.000000000 Z
11
+ date: 2024-11-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler