use_packwerk 0.50.0 → 0.50.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +6 -6
- data/lib/use_packwerk/private/pack_relationship_analyzer.rb +5 -5
- data/lib/use_packwerk/private.rb +5 -5
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fb15c026447548ee39ac7e5b7ac49bcd1f21d37c92f1690aef7e2cfa278d1bf9
|
4
|
+
data.tar.gz: e195eb9cbca25dccbd596335e84480570e7abd6272aff3b46b0a1adca3a91ca7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f5f2e2d7e0ad95a326fe8d83058db90822435922fd8756995529511c33e29ee5ae3e6c94c2b22a4572f8a39778d6a28d4a1e9eae06354a5f0e260b970f56b5be
|
7
|
+
data.tar.gz: '0911b36eda7f8aeb187d70b0ae3cc66002984f5f9f0244400ad2a6a3a34147f370affe515094a8c65de2aeff0fd7f001f0d0c98ddd18392d257ca4b64c213c83'
|
data/README.md
CHANGED
@@ -7,23 +7,23 @@ UsePackwerk is a gem that helps in creating and maintaining packs. It exists to
|
|
7
7
|
`bin/use_packwerk --help`
|
8
8
|
|
9
9
|
### Pack Creation
|
10
|
-
`bin/
|
10
|
+
`bin/use_packwerk create packs/your_pack_name_here`
|
11
11
|
|
12
12
|
### Moving files to packs
|
13
|
-
`bin/
|
13
|
+
`bin/use_packwerk move packs/your_pack_name_here path/to/file.rb path/to/directory`
|
14
14
|
This is used for moving files into a pack (the pack must already exist).
|
15
15
|
Note this works for moving files to packs from the monolith or from other packs
|
16
16
|
|
17
17
|
Make sure there are no spaces between the comma-separated list of paths of directories.
|
18
18
|
|
19
19
|
### Moving a file to public API
|
20
|
-
`bin/make_public
|
20
|
+
`bin/use_packwerk make_public path/to/file.rb,path/to/directory`
|
21
21
|
This moves a file or directory to public API (that is -- the `app/public` folder).
|
22
22
|
|
23
23
|
Make sure there are no spaces between the comma-separated list of paths of directories.
|
24
24
|
|
25
25
|
### Listing top privacy violations
|
26
|
-
`bin/list_top_privacy_violations
|
26
|
+
`bin/use_packwerk list_top_privacy_violations packs/my_pack`
|
27
27
|
Want to create interfaces? Not sure how your pack's code is being used?
|
28
28
|
|
29
29
|
You can use this command to list the top privacy violations.
|
@@ -31,7 +31,7 @@ You can use this command to list the top privacy violations.
|
|
31
31
|
If no pack name is passed in, this will list out violations across all packs.
|
32
32
|
|
33
33
|
### Listing top dependency violations
|
34
|
-
`bin/list_top_dependency_violations
|
34
|
+
`bin/use_packwerk list_top_dependency_violations packs/my_pack`
|
35
35
|
Want to see who is depending on you? Not sure how your pack's code is being used in an unstated way
|
36
36
|
|
37
37
|
You can use this command to list the top dependency violations.
|
@@ -39,7 +39,7 @@ You can use this command to list the top dependency violations.
|
|
39
39
|
If no pack name is passed in, this will list out violations across all packs.
|
40
40
|
|
41
41
|
### Adding a dependency
|
42
|
-
`bin/
|
42
|
+
`bin/use_packwerk add_dependency packs/my_pack packs/dependency_pack_name`
|
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
|
|
@@ -22,7 +22,7 @@ module UsePackwerk
|
|
22
22
|
|
23
23
|
pack_specific_content = <<~PACK_CONTENT
|
24
24
|
You are listing top #{limit} privacy violations for #{pack_name}. See #{UsePackwerk.config.documentation_link} for other utilities!
|
25
|
-
Pass in a limit to display more or less, e.g. `bin/list_top_privacy_violations
|
25
|
+
Pass in a limit to display more or less, e.g. `bin/use_packwerk list_top_privacy_violations #{pack_name} -l 1000`
|
26
26
|
|
27
27
|
This script is intended to help you find which of YOUR pack's private classes, constants, or modules other packs are using the most.
|
28
28
|
Anything not in #{pack_name}/app/public is considered private API.
|
@@ -32,7 +32,7 @@ module UsePackwerk
|
|
32
32
|
else
|
33
33
|
pack_specific_content = <<~PACK_CONTENT
|
34
34
|
You are listing top #{limit} privacy violations for all packs. See #{UsePackwerk.config.documentation_link} for other utilities!
|
35
|
-
Pass in a limit to display more or less, e.g. `bin/list_top_privacy_violations
|
35
|
+
Pass in a limit to display more or less, e.g. `bin/use_packwerk list_top_privacy_violations #{pack_name} -l 1000`
|
36
36
|
|
37
37
|
This script is intended to help you find which of YOUR pack's private classes, constants, or modules other packs are using the most.
|
38
38
|
Anything not in pack_name/app/public is considered private API.
|
@@ -72,7 +72,7 @@ module UsePackwerk
|
|
72
72
|
- packs/other_pack_a: 1
|
73
73
|
- packs/other_pack_b: 1
|
74
74
|
|
75
|
-
Lastly, remember you can use `bin/make_public
|
75
|
+
Lastly, remember you can use `bin/use_packwerk make_public #{pack_name}/path/to/file.rb` to make your class, constant, or module public API.
|
76
76
|
INTRO
|
77
77
|
Logging.print_bold_green(intro)
|
78
78
|
end
|
@@ -129,7 +129,7 @@ module UsePackwerk
|
|
129
129
|
|
130
130
|
pack_specific_content = <<~PACK_CONTENT
|
131
131
|
You are listing top #{limit} dependency violations for #{pack_name}. See #{UsePackwerk.config.documentation_link} for other utilities!
|
132
|
-
Pass in a limit to display more or less, e.g. `bin/list_top_dependency_violations
|
132
|
+
Pass in a limit to display more or less, e.g. `bin/use_packwerk list_top_dependency_violations #{pack_name} -l 1000`
|
133
133
|
|
134
134
|
This script is intended to help you find which of YOUR pack's private classes, constants, or modules other packs are using the most.
|
135
135
|
Anything not in #{pack_name}/app/public is considered private API.
|
@@ -139,7 +139,7 @@ module UsePackwerk
|
|
139
139
|
else
|
140
140
|
pack_specific_content = <<~PACK_CONTENT
|
141
141
|
You are listing top #{limit} dependency violations for all packs. See #{UsePackwerk.config.documentation_link} for other utilities!
|
142
|
-
Pass in a limit to display more or less, e.g. `
|
142
|
+
Pass in a limit to display more or less, e.g. `use_packwerk list_top_dependency_violations #{pack_name} -l 1000`
|
143
143
|
|
144
144
|
This script is intended to help you find which of YOUR pack's private classes, constants, or modules other packs are using the most.
|
145
145
|
Anything not in pack_name/app/public is considered private API.
|
data/lib/use_packwerk/private.rb
CHANGED
@@ -67,13 +67,13 @@ module UsePackwerk
|
|
67
67
|
next_steps = <<~NEXT_STEPS
|
68
68
|
Your next steps might be:
|
69
69
|
|
70
|
-
1) Move files into your pack with `bin/
|
70
|
+
1) Move files into your pack with `bin/use_packwerk move #{pack_name} path/to/file.rb`
|
71
71
|
|
72
72
|
2) Run `bin/packwerk update-deprecations` to update the violations. Make sure to run `spring stop` if you've added new load paths (new top-level directories) in your pack.
|
73
73
|
|
74
74
|
3) Update TODO lists for rubocop implemented protections. See #{UsePackwerk.config.documentation_link} for more info
|
75
75
|
|
76
|
-
4) Expose public API in #{pack_name}/app/public. Try `bin/make_public
|
76
|
+
4) Expose public API in #{pack_name}/app/public. Try `bin/use_packwerk make_public #{pack_name}/path/to/file.rb`
|
77
77
|
|
78
78
|
5) Update your readme at #{pack_name}/README.md
|
79
79
|
NEXT_STEPS
|
@@ -161,7 +161,7 @@ module UsePackwerk
|
|
161
161
|
|
162
162
|
3) Touch base with each team who owns files involved in this move
|
163
163
|
|
164
|
-
4) Expose public API in #{pack_name}/app/public. Try `bin/make_public
|
164
|
+
4) Expose public API in #{pack_name}/app/public. Try `bin/use_packwerk make_public #{pack_name}/path/to/file.rb`
|
165
165
|
|
166
166
|
5) Update your readme at #{pack_name}/README.md
|
167
167
|
NEXT_STEPS
|
@@ -344,10 +344,10 @@ module UsePackwerk
|
|
344
344
|
You can prevent other packs from using private API by using package_protections.
|
345
345
|
|
346
346
|
Want to find how your private API is being used today?
|
347
|
-
Try running: `bin/list_top_privacy_violations
|
347
|
+
Try running: `bin/use_packwerk list_top_privacy_violations #{package.name}`
|
348
348
|
|
349
349
|
Want to move something into this folder?
|
350
|
-
Try running: `bin/make_public
|
350
|
+
Try running: `bin/use_packwerk make_public #{package.name}/path/to/file.rb`
|
351
351
|
|
352
352
|
One more thing -- feel free to delete this file and replace it with a README.md describing your package in the main package directory.
|
353
353
|
|
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.50.
|
4
|
+
version: 0.50.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-
|
11
|
+
date: 2022-07-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: colorize
|