use_packwerk 0.58.0 → 0.58.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: 9b7822b93de980f116e8215d6fa79dd77f5435781a48c356e3f8b38a6be66424
4
- data.tar.gz: 8791b2a49c41bbd2464e87895acf103f8ce26d76a38e631789d5b849e12e419c
3
+ metadata.gz: 367547b5bc7ce62cd58c9ae022dd2c2825a211874867ae6e20679c5ef3f80b04
4
+ data.tar.gz: 86b4314a72763e927ba55ac7e0a17556a43b6eea907efe14680a2bcd4ceb0118
5
5
  SHA512:
6
- metadata.gz: 323d988c645a37414dc9d4c04b7932e61bd5712df6cea0313790fa8afcdec0a20fb5d46ea360906364db8988af1126459b1e40bfe6eff425c39f5ca6a3eccb32
7
- data.tar.gz: 9bea356bd9587f6d7804b19eeb5f3f1b32b6a5601c1e97091d89e48e1f40cba24a1677afabb04c791ba1d5d9ab568dd78f210010b6c1fbc983f61a787708034b
6
+ metadata.gz: e60f9cac4fa044e7d8636ea6babcf5d88ac5873a2e64dabd4cd0f32ce10928ab84b77ec16d96d4eee04464b7e5b04948ae4bb09630110d4872b2e4e10dce98ee
7
+ data.tar.gz: edc4cf6bc0d1eafb6f906941d183ba10746af8694994a4e84d027e0ecf1b2a8bdea505637fa6bec22b5d2223b33b8f12460be7ae26fa114c8ac79ed7c214e595
data/README.md CHANGED
@@ -43,6 +43,12 @@ If no pack name is passed in, this will list out violations across all packs.
43
43
 
44
44
  This can be used to quickly modify a `package.yml` file and add a dependency. It also cleans up the list of dependencies to sort the list and remove redundant entries.
45
45
 
46
+ ### Setting up Spring
47
+
48
+ [Spring](https://github.com/rails/spring) is a preloader for Rails. Although `use_packwerk` itself does not use `Rails`, this can help speed up running commands like `bin/packs` by caching the bundle.
49
+ Firstly, spring needs to know about the `bin/packs` command when spring is loading. To do that, add `require 'use_packwerk/spring_command'` to `config/spring.rb` in your application.
50
+ Secondly, to enable Spring, first run `bin/spring binstub packs` which will "springify" the generated binstub.
51
+
46
52
  ### Releasing
47
53
  Releases happen automatically through github actions once a version update is committed to `main`.
48
54
 
@@ -0,0 +1,28 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ require 'spring/commands'
5
+
6
+ module UsePackwerk
7
+ class SpringCommand
8
+ def env(*)
9
+ # Packwerk needs to run in a test environment, which has a set of autoload paths that are
10
+ # often a superset of the dev/prod paths (for example, test/support/helpers)
11
+ 'test'
12
+ end
13
+
14
+ def exec_name
15
+ 'packs'
16
+ end
17
+
18
+ def gem_name
19
+ 'use_packwerk'
20
+ end
21
+
22
+ def call
23
+ load(Gem.bin_path(gem_name, exec_name))
24
+ end
25
+ end
26
+
27
+ Spring.register_command('packs', SpringCommand.new)
28
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: use_packwerk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.58.0
4
+ version: 0.58.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gusto Engineers
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-10-17 00:00:00.000000000 Z
11
+ date: 2022-10-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: code_ownership
@@ -302,6 +302,7 @@ files:
302
302
  - lib/use_packwerk/private/interactive_cli/use_cases/validate.rb
303
303
  - lib/use_packwerk/private/pack_relationship_analyzer.rb
304
304
  - lib/use_packwerk/rubocop_post_processor.rb
305
+ - lib/use_packwerk/spring_command.rb
305
306
  - lib/use_packwerk/user_event_logger.rb
306
307
  homepage: https://github.com/rubyatscale/use_packwerk
307
308
  licenses: