packwerk 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (153) hide show
  1. checksums.yaml +7 -0
  2. data/.github/ISSUE_TEMPLATE/bug_report.md +27 -0
  3. data/.github/probots.yml +2 -0
  4. data/.github/pull_request_template.md +27 -0
  5. data/.github/workflows/ci.yml +50 -0
  6. data/.gitignore +12 -0
  7. data/.rubocop.yml +46 -0
  8. data/.ruby-version +1 -0
  9. data/CODEOWNERS +1 -0
  10. data/CODE_OF_CONDUCT.md +76 -0
  11. data/CONTRIBUTING.md +17 -0
  12. data/Gemfile +22 -0
  13. data/Gemfile.lock +236 -0
  14. data/LICENSE.md +7 -0
  15. data/README.md +73 -0
  16. data/Rakefile +13 -0
  17. data/TROUBLESHOOT.md +67 -0
  18. data/USAGE.md +250 -0
  19. data/bin/console +15 -0
  20. data/bin/setup +8 -0
  21. data/dev.yml +32 -0
  22. data/docs/cohesion.png +0 -0
  23. data/exe/packwerk +6 -0
  24. data/lib/packwerk.rb +44 -0
  25. data/lib/packwerk/application_validator.rb +343 -0
  26. data/lib/packwerk/association_inspector.rb +44 -0
  27. data/lib/packwerk/checking_deprecated_references.rb +40 -0
  28. data/lib/packwerk/cli.rb +238 -0
  29. data/lib/packwerk/configuration.rb +82 -0
  30. data/lib/packwerk/const_node_inspector.rb +44 -0
  31. data/lib/packwerk/constant_discovery.rb +60 -0
  32. data/lib/packwerk/constant_name_inspector.rb +22 -0
  33. data/lib/packwerk/dependency_checker.rb +28 -0
  34. data/lib/packwerk/deprecated_references.rb +92 -0
  35. data/lib/packwerk/file_processor.rb +43 -0
  36. data/lib/packwerk/files_for_processing.rb +67 -0
  37. data/lib/packwerk/formatters/progress_formatter.rb +46 -0
  38. data/lib/packwerk/generators/application_validation.rb +62 -0
  39. data/lib/packwerk/generators/configuration_file.rb +69 -0
  40. data/lib/packwerk/generators/inflections_file.rb +43 -0
  41. data/lib/packwerk/generators/root_package.rb +37 -0
  42. data/lib/packwerk/generators/templates/inflections.yml +6 -0
  43. data/lib/packwerk/generators/templates/package.yml +17 -0
  44. data/lib/packwerk/generators/templates/packwerk +23 -0
  45. data/lib/packwerk/generators/templates/packwerk.yml.erb +23 -0
  46. data/lib/packwerk/generators/templates/packwerk_validator_test.rb +11 -0
  47. data/lib/packwerk/graph.rb +74 -0
  48. data/lib/packwerk/inflections/custom.rb +33 -0
  49. data/lib/packwerk/inflections/default.rb +73 -0
  50. data/lib/packwerk/inflector.rb +41 -0
  51. data/lib/packwerk/node.rb +259 -0
  52. data/lib/packwerk/node_processor.rb +49 -0
  53. data/lib/packwerk/node_visitor.rb +22 -0
  54. data/lib/packwerk/offense.rb +44 -0
  55. data/lib/packwerk/output_styles.rb +41 -0
  56. data/lib/packwerk/package.rb +56 -0
  57. data/lib/packwerk/package_set.rb +59 -0
  58. data/lib/packwerk/parsed_constant_definitions.rb +62 -0
  59. data/lib/packwerk/parsers.rb +23 -0
  60. data/lib/packwerk/parsers/erb.rb +66 -0
  61. data/lib/packwerk/parsers/factory.rb +34 -0
  62. data/lib/packwerk/parsers/ruby.rb +42 -0
  63. data/lib/packwerk/privacy_checker.rb +45 -0
  64. data/lib/packwerk/reference.rb +6 -0
  65. data/lib/packwerk/reference_extractor.rb +81 -0
  66. data/lib/packwerk/reference_lister.rb +23 -0
  67. data/lib/packwerk/run_context.rb +103 -0
  68. data/lib/packwerk/sanity_checker.rb +10 -0
  69. data/lib/packwerk/spring_command.rb +28 -0
  70. data/lib/packwerk/updating_deprecated_references.rb +51 -0
  71. data/lib/packwerk/version.rb +6 -0
  72. data/lib/packwerk/violation_type.rb +13 -0
  73. data/library.yml +6 -0
  74. data/packwerk.gemspec +58 -0
  75. data/service.yml +6 -0
  76. data/shipit.rubygems.yml +1 -0
  77. data/sorbet/config +2 -0
  78. data/sorbet/rbi/gems/actioncable@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +840 -0
  79. data/sorbet/rbi/gems/actionmailbox@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +571 -0
  80. data/sorbet/rbi/gems/actionmailer@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +568 -0
  81. data/sorbet/rbi/gems/actionpack@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +5216 -0
  82. data/sorbet/rbi/gems/actiontext@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +663 -0
  83. data/sorbet/rbi/gems/actionview@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +2504 -0
  84. data/sorbet/rbi/gems/activejob@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +635 -0
  85. data/sorbet/rbi/gems/activemodel@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +1201 -0
  86. data/sorbet/rbi/gems/activerecord@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +8011 -0
  87. data/sorbet/rbi/gems/activestorage@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +904 -0
  88. data/sorbet/rbi/gems/activesupport@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +3888 -0
  89. data/sorbet/rbi/gems/ast@2.4.1.rbi +54 -0
  90. data/sorbet/rbi/gems/better_html@1.0.15.rbi +317 -0
  91. data/sorbet/rbi/gems/builder@3.2.4.rbi +8 -0
  92. data/sorbet/rbi/gems/byebug@11.1.3.rbi +8 -0
  93. data/sorbet/rbi/gems/coderay@1.1.3.rbi +8 -0
  94. data/sorbet/rbi/gems/colorize@0.8.1.rbi +40 -0
  95. data/sorbet/rbi/gems/commander@4.5.2.rbi +8 -0
  96. data/sorbet/rbi/gems/concurrent-ruby@1.1.6.rbi +1966 -0
  97. data/sorbet/rbi/gems/constant_resolver@0.1.5.rbi +26 -0
  98. data/sorbet/rbi/gems/crass@1.0.6.rbi +138 -0
  99. data/sorbet/rbi/gems/erubi@1.9.0.rbi +39 -0
  100. data/sorbet/rbi/gems/globalid@0.4.2.rbi +178 -0
  101. data/sorbet/rbi/gems/highline@2.0.3.rbi +8 -0
  102. data/sorbet/rbi/gems/html_tokenizer@0.0.7.rbi +46 -0
  103. data/sorbet/rbi/gems/i18n@1.8.2.rbi +633 -0
  104. data/sorbet/rbi/gems/jaro_winkler@1.5.4.rbi +8 -0
  105. data/sorbet/rbi/gems/loofah@2.5.0.rbi +272 -0
  106. data/sorbet/rbi/gems/m@1.5.1.rbi +108 -0
  107. data/sorbet/rbi/gems/mail@2.7.1.rbi +2490 -0
  108. data/sorbet/rbi/gems/marcel@0.3.3.rbi +30 -0
  109. data/sorbet/rbi/gems/method_source@1.0.0.rbi +76 -0
  110. data/sorbet/rbi/gems/mimemagic@0.3.5.rbi +47 -0
  111. data/sorbet/rbi/gems/mini_mime@1.0.2.rbi +71 -0
  112. data/sorbet/rbi/gems/mini_portile2@2.4.0.rbi +8 -0
  113. data/sorbet/rbi/gems/minitest@5.14.0.rbi +542 -0
  114. data/sorbet/rbi/gems/mocha@1.11.2.rbi +964 -0
  115. data/sorbet/rbi/gems/nio4r@2.5.2.rbi +89 -0
  116. data/sorbet/rbi/gems/nokogiri@1.10.9.rbi +1608 -0
  117. data/sorbet/rbi/gems/parallel@1.19.1.rbi +8 -0
  118. data/sorbet/rbi/gems/parlour@4.0.1.rbi +561 -0
  119. data/sorbet/rbi/gems/parser@2.7.1.4.rbi +1632 -0
  120. data/sorbet/rbi/gems/pry@0.13.1.rbi +8 -0
  121. data/sorbet/rbi/gems/rack-test@1.1.0.rbi +335 -0
  122. data/sorbet/rbi/gems/rack@2.2.2.rbi +1730 -0
  123. data/sorbet/rbi/gems/rails-dom-testing@2.0.3.rbi +123 -0
  124. data/sorbet/rbi/gems/rails-html-sanitizer@1.3.0.rbi +213 -0
  125. data/sorbet/rbi/gems/rails@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +8 -0
  126. data/sorbet/rbi/gems/railties@6.1.0.alpha-d80c18a391e33552ae2d943e68af56946f883f65.rbi +869 -0
  127. data/sorbet/rbi/gems/rainbow@3.0.0.rbi +155 -0
  128. data/sorbet/rbi/gems/rake@13.0.1.rbi +841 -0
  129. data/sorbet/rbi/gems/rexml@3.2.4.rbi +8 -0
  130. data/sorbet/rbi/gems/rubocop-performance@1.5.2.rbi +8 -0
  131. data/sorbet/rbi/gems/rubocop-shopify@1.0.2.rbi +8 -0
  132. data/sorbet/rbi/gems/rubocop-sorbet@0.3.7.rbi +8 -0
  133. data/sorbet/rbi/gems/rubocop@0.82.0.rbi +8 -0
  134. data/sorbet/rbi/gems/ruby-progressbar@1.10.1.rbi +8 -0
  135. data/sorbet/rbi/gems/smart_properties@1.15.0.rbi +168 -0
  136. data/sorbet/rbi/gems/spoom@1.0.4.rbi +418 -0
  137. data/sorbet/rbi/gems/spring@2.1.0.rbi +160 -0
  138. data/sorbet/rbi/gems/sprockets-rails@3.2.1.rbi +431 -0
  139. data/sorbet/rbi/gems/sprockets@4.0.0.rbi +1132 -0
  140. data/sorbet/rbi/gems/tapioca@0.4.5.rbi +518 -0
  141. data/sorbet/rbi/gems/thor@1.0.1.rbi +892 -0
  142. data/sorbet/rbi/gems/tzinfo@2.0.2.rbi +547 -0
  143. data/sorbet/rbi/gems/unicode-display_width@1.7.0.rbi +8 -0
  144. data/sorbet/rbi/gems/websocket-driver@0.7.1.rbi +438 -0
  145. data/sorbet/rbi/gems/websocket-extensions@0.1.4.rbi +71 -0
  146. data/sorbet/rbi/gems/zeitwerk@2.3.0.rbi +8 -0
  147. data/sorbet/tapioca/require.rb +25 -0
  148. data/static/packwerk-check-demo.png +0 -0
  149. data/static/packwerk_check.gif +0 -0
  150. data/static/packwerk_check_violation.gif +0 -0
  151. data/static/packwerk_update.gif +0 -0
  152. data/static/packwerk_validate.gif +0 -0
  153. metadata +341 -0
@@ -0,0 +1,155 @@
1
+ # DO NOT EDIT MANUALLY
2
+ # This is an autogenerated file for types exported from the `rainbow` gem.
3
+ # Please instead update this file by running `dev typecheck update`.
4
+
5
+ # typed: true
6
+
7
+ module Rainbow
8
+ class << self
9
+ def enabled; end
10
+ def enabled=(value); end
11
+ def global; end
12
+ def new; end
13
+ def uncolor(string); end
14
+ end
15
+ end
16
+
17
+ class Rainbow::Color
18
+ def ground; end
19
+
20
+ class << self
21
+ def build(ground, values); end
22
+ def parse_hex_color(hex); end
23
+ end
24
+ end
25
+
26
+ class Rainbow::Color::Indexed < ::Rainbow::Color
27
+ def initialize(ground, num); end
28
+
29
+ def codes; end
30
+ def num; end
31
+ end
32
+
33
+ class Rainbow::Color::Named < ::Rainbow::Color::Indexed
34
+ def initialize(ground, name); end
35
+
36
+ class << self
37
+ def color_names; end
38
+ def valid_names; end
39
+ end
40
+ end
41
+
42
+ Rainbow::Color::Named::NAMES = T.let(T.unsafe(nil), Hash)
43
+
44
+ class Rainbow::Color::RGB < ::Rainbow::Color::Indexed
45
+ def initialize(ground, *values); end
46
+
47
+ def b; end
48
+ def codes; end
49
+ def g; end
50
+ def r; end
51
+
52
+ private
53
+
54
+ def code_from_rgb; end
55
+
56
+ class << self
57
+ def to_ansi_domain(value); end
58
+ end
59
+ end
60
+
61
+ class Rainbow::Color::X11Named < ::Rainbow::Color::RGB
62
+ include(::Rainbow::X11ColorNames)
63
+
64
+ def initialize(ground, name); end
65
+
66
+ class << self
67
+ def color_names; end
68
+ def valid_names; end
69
+ end
70
+ end
71
+
72
+ class Rainbow::NullPresenter < ::String
73
+ def background(*_values); end
74
+ def bg(*_values); end
75
+ def black; end
76
+ def blink; end
77
+ def blue; end
78
+ def bold; end
79
+ def bright; end
80
+ def color(*_values); end
81
+ def cyan; end
82
+ def dark; end
83
+ def faint; end
84
+ def fg(*_values); end
85
+ def foreground(*_values); end
86
+ def green; end
87
+ def hide; end
88
+ def inverse; end
89
+ def italic; end
90
+ def magenta; end
91
+ def method_missing(method_name, *args); end
92
+ def red; end
93
+ def reset; end
94
+ def underline; end
95
+ def white; end
96
+ def yellow; end
97
+
98
+ private
99
+
100
+ def respond_to_missing?(method_name, *args); end
101
+ end
102
+
103
+ class Rainbow::Presenter < ::String
104
+ def background(*values); end
105
+ def bg(*values); end
106
+ def black; end
107
+ def blink; end
108
+ def blue; end
109
+ def bold; end
110
+ def bright; end
111
+ def color(*values); end
112
+ def cyan; end
113
+ def dark; end
114
+ def faint; end
115
+ def fg(*values); end
116
+ def foreground(*values); end
117
+ def green; end
118
+ def hide; end
119
+ def inverse; end
120
+ def italic; end
121
+ def magenta; end
122
+ def method_missing(method_name, *args); end
123
+ def red; end
124
+ def reset; end
125
+ def underline; end
126
+ def white; end
127
+ def yellow; end
128
+
129
+ private
130
+
131
+ def respond_to_missing?(method_name, *args); end
132
+ def wrap_with_sgr(codes); end
133
+ end
134
+
135
+ Rainbow::Presenter::TERM_EFFECTS = T.let(T.unsafe(nil), Hash)
136
+
137
+ class Rainbow::StringUtils
138
+ class << self
139
+ def uncolor(string); end
140
+ def wrap_with_sgr(string, codes); end
141
+ end
142
+ end
143
+
144
+ class Rainbow::Wrapper
145
+ def initialize(enabled = T.unsafe(nil)); end
146
+
147
+ def enabled; end
148
+ def enabled=(_); end
149
+ def wrap(string); end
150
+ end
151
+
152
+ module Rainbow::X11ColorNames
153
+ end
154
+
155
+ Rainbow::X11ColorNames::NAMES = T.let(T.unsafe(nil), Hash)
@@ -0,0 +1,841 @@
1
+ # DO NOT EDIT MANUALLY
2
+ # This is an autogenerated file for types exported from the `rake` gem.
3
+ # Please instead update this file by running `dev typecheck update`.
4
+
5
+ # typed: true
6
+
7
+ FileList = Rake::FileList
8
+
9
+ module FileUtils
10
+ include(::FileUtils::StreamUtils_)
11
+ extend(::FileUtils::StreamUtils_)
12
+
13
+ def ruby(*args, **options, &block); end
14
+ def safe_ln(*args, **options); end
15
+ def sh(*cmd, &block); end
16
+ def split_all(path); end
17
+
18
+ private
19
+
20
+ def create_shell_runner(cmd); end
21
+ def set_verbose_option(options); end
22
+ def sh_show_command(cmd); end
23
+ end
24
+
25
+ FileUtils::LN_SUPPORTED = T.let(T.unsafe(nil), Array)
26
+
27
+ FileUtils::RUBY = T.let(T.unsafe(nil), String)
28
+
29
+ class Module
30
+ include(::ActiveSupport::Dependencies::ModuleConstMissing)
31
+ include(::Module::Concerning)
32
+
33
+ def rake_extension(method); end
34
+ end
35
+
36
+ Module::DELEGATION_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array)
37
+
38
+ Module::DELEGATION_RESERVED_METHOD_NAMES = T.let(T.unsafe(nil), Set)
39
+
40
+ Module::RUBY_RESERVED_KEYWORDS = T.let(T.unsafe(nil), Array)
41
+
42
+ module Rake
43
+ extend(::FileUtils::StreamUtils_)
44
+ extend(::FileUtils)
45
+ extend(::Rake::FileUtilsExt)
46
+
47
+ class << self
48
+ def add_rakelib(*files); end
49
+ def application; end
50
+ def application=(app); end
51
+ def each_dir_parent(dir); end
52
+ def from_pathname(path); end
53
+ def load_rakefile(path); end
54
+ def original_dir; end
55
+ def suggested_thread_count; end
56
+ def with_application(block_application = T.unsafe(nil)); end
57
+ end
58
+ end
59
+
60
+ class Rake::Application
61
+ include(::Rake::TaskManager)
62
+ include(::Rake::TraceOutput)
63
+
64
+ def initialize; end
65
+
66
+ def add_import(fn); end
67
+ def add_loader(ext, loader); end
68
+ def collect_command_line_tasks(args); end
69
+ def default_task_name; end
70
+ def deprecate(old_usage, new_usage, call_site); end
71
+ def display_cause_details(ex); end
72
+ def display_error_message(ex); end
73
+ def display_exception_backtrace(ex); end
74
+ def display_exception_details(ex); end
75
+ def display_exception_details_seen; end
76
+ def display_exception_message_details(ex); end
77
+ def display_prerequisites; end
78
+ def display_tasks_and_comments; end
79
+ def dynamic_width; end
80
+ def dynamic_width_stty; end
81
+ def dynamic_width_tput; end
82
+ def exit_because_of_exception(ex); end
83
+ def find_rakefile_location; end
84
+ def handle_options(argv); end
85
+ def has_cause?(ex); end
86
+ def have_rakefile; end
87
+ def init(app_name = T.unsafe(nil), argv = T.unsafe(nil)); end
88
+ def invoke_task(task_string); end
89
+ def load_imports; end
90
+ def load_rakefile; end
91
+ def name; end
92
+ def options; end
93
+ def original_dir; end
94
+ def parse_task_string(string); end
95
+ def print_rakefile_directory(location); end
96
+ def rake_require(file_name, paths = T.unsafe(nil), loaded = T.unsafe(nil)); end
97
+ def rakefile; end
98
+ def rakefile_location(backtrace = T.unsafe(nil)); end
99
+ def raw_load_rakefile; end
100
+ def run(argv = T.unsafe(nil)); end
101
+ def run_with_threads; end
102
+ def set_default_options; end
103
+ def standard_exception_handling; end
104
+ def standard_rake_options; end
105
+ def system_dir; end
106
+ def terminal_columns; end
107
+ def terminal_columns=(_); end
108
+ def terminal_width; end
109
+ def thread_pool; end
110
+ def top_level; end
111
+ def top_level_tasks; end
112
+ def trace(*strings); end
113
+ def truncate(string, width); end
114
+ def truncate_output?; end
115
+ def tty_output=(_); end
116
+ def tty_output?; end
117
+ def unix?; end
118
+ def windows?; end
119
+
120
+ private
121
+
122
+ def glob(path, &block); end
123
+ def has_chain?(exception); end
124
+ def select_tasks_to_show(options, show_tasks, value); end
125
+ def select_trace_output(options, trace_option, value); end
126
+ def sort_options(options); end
127
+ def standard_system_dir; end
128
+ end
129
+
130
+ Rake::Application::DEFAULT_RAKEFILES = T.let(T.unsafe(nil), Array)
131
+
132
+ module Rake::Backtrace
133
+ class << self
134
+ def collapse(backtrace); end
135
+ end
136
+ end
137
+
138
+ Rake::Backtrace::SUPPRESSED_PATHS = T.let(T.unsafe(nil), Array)
139
+
140
+ Rake::Backtrace::SUPPRESSED_PATHS_RE = T.let(T.unsafe(nil), String)
141
+
142
+ Rake::Backtrace::SUPPRESS_PATTERN = T.let(T.unsafe(nil), Regexp)
143
+
144
+ Rake::Backtrace::SYS_KEYS = T.let(T.unsafe(nil), Array)
145
+
146
+ Rake::Backtrace::SYS_PATHS = T.let(T.unsafe(nil), Array)
147
+
148
+ module Rake::Cloneable
149
+
150
+ private
151
+
152
+ def initialize_copy(source); end
153
+ end
154
+
155
+ class Rake::CommandLineOptionError < ::StandardError
156
+ end
157
+
158
+ class Rake::CpuCounter
159
+ def count; end
160
+ def count_with_default(default = T.unsafe(nil)); end
161
+
162
+ class << self
163
+ def count; end
164
+ end
165
+ end
166
+
167
+ module Rake::DSL
168
+ include(::FileUtils::StreamUtils_)
169
+ include(::FileUtils)
170
+ include(::Rake::FileUtilsExt)
171
+
172
+
173
+ private
174
+
175
+ def desc(description); end
176
+ def directory(*args, &block); end
177
+ def file(*args, &block); end
178
+ def file_create(*args, &block); end
179
+ def import(*fns); end
180
+ def multitask(*args, &block); end
181
+ def namespace(name = T.unsafe(nil), &block); end
182
+ def rule(*args, &block); end
183
+ def task(*args, &block); end
184
+ end
185
+
186
+ class Rake::DefaultLoader
187
+ def load(fn); end
188
+ end
189
+
190
+ Rake::EARLY = T.let(T.unsafe(nil), Rake::EarlyTime)
191
+
192
+ Rake::EMPTY_TASK_ARGS = T.let(T.unsafe(nil), Rake::TaskArguments)
193
+
194
+ class Rake::EarlyTime
195
+ include(::Comparable)
196
+ include(::Singleton)
197
+ extend(::Singleton::SingletonClassMethods)
198
+
199
+ def <=>(other); end
200
+ def to_s; end
201
+
202
+ class << self
203
+ def instance; end
204
+ end
205
+ end
206
+
207
+ class Rake::FileCreationTask < ::Rake::FileTask
208
+ def needed?; end
209
+ def timestamp; end
210
+ end
211
+
212
+ class Rake::FileList
213
+ include(::Rake::Cloneable)
214
+
215
+ def initialize(*patterns); end
216
+
217
+ def &(*args, &block); end
218
+ def *(other); end
219
+ def +(*args, &block); end
220
+ def -(*args, &block); end
221
+ def <<(obj); end
222
+ def <=>(*args, &block); end
223
+ def ==(array); end
224
+ def [](*args, &block); end
225
+ def []=(*args, &block); end
226
+ def add(*filenames); end
227
+ def all?(*args, &block); end
228
+ def any?(*args, &block); end
229
+ def append(*args, &block); end
230
+ def assoc(*args, &block); end
231
+ def at(*args, &block); end
232
+ def bsearch(*args, &block); end
233
+ def bsearch_index(*args, &block); end
234
+ def chain(*args, &block); end
235
+ def chunk(*args, &block); end
236
+ def chunk_while(*args, &block); end
237
+ def clear(*args, &block); end
238
+ def clear_exclude; end
239
+ def collect(*args, &block); end
240
+ def collect!(*args, &block); end
241
+ def collect_concat(*args, &block); end
242
+ def combination(*args, &block); end
243
+ def compact(*args, &block); end
244
+ def compact!(*args, &block); end
245
+ def concat(*args, &block); end
246
+ def count(*args, &block); end
247
+ def cycle(*args, &block); end
248
+ def delete(*args, &block); end
249
+ def delete_at(*args, &block); end
250
+ def delete_if(*args, &block); end
251
+ def detect(*args, &block); end
252
+ def difference(*args, &block); end
253
+ def dig(*args, &block); end
254
+ def drop(*args, &block); end
255
+ def drop_while(*args, &block); end
256
+ def each(*args, &block); end
257
+ def each_cons(*args, &block); end
258
+ def each_entry(*args, &block); end
259
+ def each_index(*args, &block); end
260
+ def each_slice(*args, &block); end
261
+ def each_with_index(*args, &block); end
262
+ def each_with_object(*args, &block); end
263
+ def egrep(pattern, *options); end
264
+ def empty?(*args, &block); end
265
+ def entries(*args, &block); end
266
+ def exclude(*patterns, &block); end
267
+ def excluded_from_list?(fn); end
268
+ def existing; end
269
+ def existing!; end
270
+ def ext(newext = T.unsafe(nil)); end
271
+ def fetch(*args, &block); end
272
+ def fill(*args, &block); end
273
+ def filter(*args, &block); end
274
+ def filter!(*args, &block); end
275
+ def find(*args, &block); end
276
+ def find_all(*args, &block); end
277
+ def find_index(*args, &block); end
278
+ def first(*args, &block); end
279
+ def flat_map(*args, &block); end
280
+ def flatten(*args, &block); end
281
+ def flatten!(*args, &block); end
282
+ def grep(*args, &block); end
283
+ def grep_v(*args, &block); end
284
+ def group_by(*args, &block); end
285
+ def gsub(pat, rep); end
286
+ def gsub!(pat, rep); end
287
+ def import(array); end
288
+ def include(*filenames); end
289
+ def include?(*args, &block); end
290
+ def index(*args, &block); end
291
+ def inject(*args, &block); end
292
+ def insert(*args, &block); end
293
+ def inspect(*args, &block); end
294
+ def is_a?(klass); end
295
+ def join(*args, &block); end
296
+ def keep_if(*args, &block); end
297
+ def kind_of?(klass); end
298
+ def last(*args, &block); end
299
+ def lazy(*args, &block); end
300
+ def length(*args, &block); end
301
+ def map(*args, &block); end
302
+ def map!(*args, &block); end
303
+ def max(*args, &block); end
304
+ def max_by(*args, &block); end
305
+ def member?(*args, &block); end
306
+ def min(*args, &block); end
307
+ def min_by(*args, &block); end
308
+ def minmax(*args, &block); end
309
+ def minmax_by(*args, &block); end
310
+ def none?(*args, &block); end
311
+ def one?(*args, &block); end
312
+ def pack(*args, &block); end
313
+ def partition(&block); end
314
+ def pathmap(spec = T.unsafe(nil), &block); end
315
+ def permutation(*args, &block); end
316
+ def pop(*args, &block); end
317
+ def prepend(*args, &block); end
318
+ def product(*args, &block); end
319
+ def push(*args, &block); end
320
+ def rassoc(*args, &block); end
321
+ def reduce(*args, &block); end
322
+ def reject(*args, &block); end
323
+ def reject!(*args, &block); end
324
+ def repeated_combination(*args, &block); end
325
+ def repeated_permutation(*args, &block); end
326
+ def replace(*args, &block); end
327
+ def resolve; end
328
+ def reverse(*args, &block); end
329
+ def reverse!(*args, &block); end
330
+ def reverse_each(*args, &block); end
331
+ def rindex(*args, &block); end
332
+ def rotate(*args, &block); end
333
+ def rotate!(*args, &block); end
334
+ def sample(*args, &block); end
335
+ def select(*args, &block); end
336
+ def select!(*args, &block); end
337
+ def shelljoin(*args, &block); end
338
+ def shift(*args, &block); end
339
+ def shuffle(*args, &block); end
340
+ def shuffle!(*args, &block); end
341
+ def size(*args, &block); end
342
+ def slice(*args, &block); end
343
+ def slice!(*args, &block); end
344
+ def slice_after(*args, &block); end
345
+ def slice_before(*args, &block); end
346
+ def slice_when(*args, &block); end
347
+ def sort(*args, &block); end
348
+ def sort!(*args, &block); end
349
+ def sort_by(*args, &block); end
350
+ def sort_by!(*args, &block); end
351
+ def sub(pat, rep); end
352
+ def sub!(pat, rep); end
353
+ def sum(*args, &block); end
354
+ def take(*args, &block); end
355
+ def take_while(*args, &block); end
356
+ def to_a; end
357
+ def to_ary; end
358
+ def to_h(*args, &block); end
359
+ def to_s; end
360
+ def to_set(*args, &block); end
361
+ def transpose(*args, &block); end
362
+ def union(*args, &block); end
363
+ def uniq(*args, &block); end
364
+ def uniq!(*args, &block); end
365
+ def unshift(*args, &block); end
366
+ def values_at(*args, &block); end
367
+ def zip(*args, &block); end
368
+ def |(*args, &block); end
369
+
370
+ private
371
+
372
+ def add_matching(pattern); end
373
+ def resolve_add(fn); end
374
+ def resolve_exclude; end
375
+
376
+ class << self
377
+ def [](*args); end
378
+ def glob(pattern, *args); end
379
+ end
380
+ end
381
+
382
+ Rake::FileList::ARRAY_METHODS = T.let(T.unsafe(nil), Array)
383
+
384
+ Rake::FileList::DEFAULT_IGNORE_PATTERNS = T.let(T.unsafe(nil), Array)
385
+
386
+ Rake::FileList::DEFAULT_IGNORE_PROCS = T.let(T.unsafe(nil), Array)
387
+
388
+ Rake::FileList::DELEGATING_METHODS = T.let(T.unsafe(nil), Array)
389
+
390
+ Rake::FileList::GLOB_PATTERN = T.let(T.unsafe(nil), Regexp)
391
+
392
+ Rake::FileList::MUST_DEFINE = T.let(T.unsafe(nil), Array)
393
+
394
+ Rake::FileList::MUST_NOT_DEFINE = T.let(T.unsafe(nil), Array)
395
+
396
+ Rake::FileList::SPECIAL_RETURN = T.let(T.unsafe(nil), Array)
397
+
398
+ class Rake::FileTask < ::Rake::Task
399
+ def needed?; end
400
+ def timestamp; end
401
+
402
+ private
403
+
404
+ def out_of_date?(stamp); end
405
+
406
+ class << self
407
+ def scope_name(scope, task_name); end
408
+ end
409
+ end
410
+
411
+ module Rake::FileUtilsExt
412
+ include(::FileUtils::StreamUtils_)
413
+ include(::FileUtils)
414
+ extend(::FileUtils::StreamUtils_)
415
+ extend(::FileUtils)
416
+ extend(::Rake::FileUtilsExt)
417
+
418
+ def cd(*args, **options, &block); end
419
+ def chdir(*args, **options, &block); end
420
+ def chmod(*args, **options, &block); end
421
+ def chmod_R(*args, **options, &block); end
422
+ def chown(*args, **options, &block); end
423
+ def chown_R(*args, **options, &block); end
424
+ def copy(*args, **options, &block); end
425
+ def cp(*args, **options, &block); end
426
+ def cp_lr(*args, **options, &block); end
427
+ def cp_r(*args, **options, &block); end
428
+ def install(*args, **options, &block); end
429
+ def link(*args, **options, &block); end
430
+ def ln(*args, **options, &block); end
431
+ def ln_s(*args, **options, &block); end
432
+ def ln_sf(*args, **options, &block); end
433
+ def makedirs(*args, **options, &block); end
434
+ def mkdir(*args, **options, &block); end
435
+ def mkdir_p(*args, **options, &block); end
436
+ def mkpath(*args, **options, &block); end
437
+ def move(*args, **options, &block); end
438
+ def mv(*args, **options, &block); end
439
+ def nowrite(value = T.unsafe(nil)); end
440
+ def rake_check_options(options, *optdecl); end
441
+ def rake_output_message(message); end
442
+ def remove(*args, **options, &block); end
443
+ def rm(*args, **options, &block); end
444
+ def rm_f(*args, **options, &block); end
445
+ def rm_r(*args, **options, &block); end
446
+ def rm_rf(*args, **options, &block); end
447
+ def rmdir(*args, **options, &block); end
448
+ def rmtree(*args, **options, &block); end
449
+ def safe_unlink(*args, **options, &block); end
450
+ def symlink(*args, **options, &block); end
451
+ def touch(*args, **options, &block); end
452
+ def verbose(value = T.unsafe(nil)); end
453
+ def when_writing(msg = T.unsafe(nil)); end
454
+
455
+ class << self
456
+ def nowrite_flag; end
457
+ def nowrite_flag=(_); end
458
+ def verbose_flag; end
459
+ def verbose_flag=(_); end
460
+ end
461
+ end
462
+
463
+ Rake::FileUtilsExt::DEFAULT = T.let(T.unsafe(nil), Object)
464
+
465
+ class Rake::InvocationChain < ::Rake::LinkedList
466
+ def append(invocation); end
467
+ def member?(invocation); end
468
+ def to_s; end
469
+
470
+ private
471
+
472
+ def prefix; end
473
+
474
+ class << self
475
+ def append(invocation, chain); end
476
+ end
477
+ end
478
+
479
+ Rake::InvocationChain::EMPTY = T.let(T.unsafe(nil), Rake::InvocationChain::EmptyInvocationChain)
480
+
481
+ class Rake::InvocationChain::EmptyInvocationChain < ::Rake::LinkedList::EmptyLinkedList
482
+ def append(invocation); end
483
+ def member?(obj); end
484
+ def to_s; end
485
+ end
486
+
487
+ module Rake::InvocationExceptionMixin
488
+ def chain; end
489
+ def chain=(value); end
490
+ end
491
+
492
+ Rake::LATE = T.let(T.unsafe(nil), Rake::LateTime)
493
+
494
+ class Rake::LateTime
495
+ include(::Comparable)
496
+ include(::Singleton)
497
+ extend(::Singleton::SingletonClassMethods)
498
+
499
+ def <=>(other); end
500
+ def to_s; end
501
+
502
+ class << self
503
+ def instance; end
504
+ end
505
+ end
506
+
507
+ class Rake::LinkedList
508
+ include(::Enumerable)
509
+
510
+ def initialize(head, tail = T.unsafe(nil)); end
511
+
512
+ def ==(other); end
513
+ def conj(item); end
514
+ def each; end
515
+ def empty?; end
516
+ def head; end
517
+ def inspect; end
518
+ def tail; end
519
+ def to_s; end
520
+
521
+ class << self
522
+ def cons(head, tail); end
523
+ def empty; end
524
+ def make(*args); end
525
+ end
526
+ end
527
+
528
+ Rake::LinkedList::EMPTY = T.let(T.unsafe(nil), Rake::LinkedList::EmptyLinkedList)
529
+
530
+ class Rake::LinkedList::EmptyLinkedList < ::Rake::LinkedList
531
+ def initialize; end
532
+
533
+ def empty?; end
534
+
535
+ class << self
536
+ def cons(head, tail); end
537
+ end
538
+ end
539
+
540
+ class Rake::MultiTask < ::Rake::Task
541
+
542
+ private
543
+
544
+ def invoke_prerequisites(task_args, invocation_chain); end
545
+ end
546
+
547
+ class Rake::NameSpace
548
+ def initialize(task_manager, scope_list); end
549
+
550
+ def [](name); end
551
+ def scope; end
552
+ def tasks; end
553
+ end
554
+
555
+ module Rake::PrivateReader
556
+ mixes_in_class_methods(::Rake::PrivateReader::ClassMethods)
557
+
558
+ class << self
559
+ def included(base); end
560
+ end
561
+ end
562
+
563
+ module Rake::PrivateReader::ClassMethods
564
+ def private_reader(*names); end
565
+ end
566
+
567
+ class Rake::Promise
568
+ def initialize(args, &block); end
569
+
570
+ def recorder; end
571
+ def recorder=(_); end
572
+ def value; end
573
+ def work; end
574
+
575
+ private
576
+
577
+ def chore; end
578
+ def complete?; end
579
+ def discard; end
580
+ def error?; end
581
+ def result?; end
582
+ def stat(*args); end
583
+ end
584
+
585
+ Rake::Promise::NOT_SET = T.let(T.unsafe(nil), Object)
586
+
587
+ class Rake::PseudoStatus
588
+ def initialize(code = T.unsafe(nil)); end
589
+
590
+ def >>(n); end
591
+ def exited?; end
592
+ def exitstatus; end
593
+ def stopped?; end
594
+ def to_i; end
595
+ end
596
+
597
+ class Rake::RuleRecursionOverflowError < ::StandardError
598
+ def initialize(*args); end
599
+
600
+ def add_target(target); end
601
+ def message; end
602
+ end
603
+
604
+ class Rake::Scope < ::Rake::LinkedList
605
+ def path; end
606
+ def path_with_task_name(task_name); end
607
+ def trim(n); end
608
+ end
609
+
610
+ Rake::Scope::EMPTY = T.let(T.unsafe(nil), Rake::Scope::EmptyScope)
611
+
612
+ class Rake::Scope::EmptyScope < ::Rake::LinkedList::EmptyLinkedList
613
+ def path; end
614
+ def path_with_task_name(task_name); end
615
+ end
616
+
617
+ class Rake::Task
618
+ def initialize(task_name, app); end
619
+
620
+ def actions; end
621
+ def add_description(description); end
622
+ def all_prerequisite_tasks; end
623
+ def already_invoked; end
624
+ def application; end
625
+ def application=(_); end
626
+ def arg_description; end
627
+ def arg_names; end
628
+ def clear; end
629
+ def clear_actions; end
630
+ def clear_args; end
631
+ def clear_comments; end
632
+ def clear_prerequisites; end
633
+ def comment; end
634
+ def comment=(comment); end
635
+ def enhance(deps = T.unsafe(nil), &block); end
636
+ def execute(args = T.unsafe(nil)); end
637
+ def full_comment; end
638
+ def inspect; end
639
+ def investigation; end
640
+ def invoke(*args); end
641
+ def invoke_prerequisites(task_args, invocation_chain); end
642
+ def invoke_prerequisites_concurrently(task_args, invocation_chain); end
643
+ def locations; end
644
+ def name; end
645
+ def name_with_args; end
646
+ def needed?; end
647
+ def order_only_prerequisites; end
648
+ def prereqs; end
649
+ def prerequisite_tasks; end
650
+ def prerequisites; end
651
+ def reenable; end
652
+ def scope; end
653
+ def set_arg_names(args); end
654
+ def source; end
655
+ def sources; end
656
+ def sources=(_); end
657
+ def timestamp; end
658
+ def to_s; end
659
+ def |(deps); end
660
+
661
+ protected
662
+
663
+ def collect_prerequisites(seen); end
664
+ def invoke_with_call_chain(task_args, invocation_chain); end
665
+
666
+ private
667
+
668
+ def add_chain_to(exception, new_chain); end
669
+ def add_comment(comment); end
670
+ def first_sentence(string); end
671
+ def format_trace_flags; end
672
+ def lookup_prerequisite(prerequisite_name); end
673
+ def transform_comments(separator, &block); end
674
+
675
+ class << self
676
+ def [](task_name); end
677
+ def clear; end
678
+ def create_rule(*args, &block); end
679
+ def define_task(*args, &block); end
680
+ def format_deps(deps); end
681
+ def scope_name(scope, task_name); end
682
+ def task_defined?(task_name); end
683
+ def tasks; end
684
+ end
685
+ end
686
+
687
+ class Rake::TaskArgumentError < ::ArgumentError
688
+ end
689
+
690
+ class Rake::TaskArguments
691
+ include(::Enumerable)
692
+
693
+ def initialize(names, values, parent = T.unsafe(nil)); end
694
+
695
+ def [](index); end
696
+ def each(&block); end
697
+ def extras; end
698
+ def fetch(*args, &block); end
699
+ def has_key?(key); end
700
+ def inspect; end
701
+ def key?(key); end
702
+ def method_missing(sym, *args); end
703
+ def names; end
704
+ def new_scope(names); end
705
+ def to_a; end
706
+ def to_hash; end
707
+ def to_s; end
708
+ def values_at(*keys); end
709
+ def with_defaults(defaults); end
710
+
711
+ protected
712
+
713
+ def lookup(name); end
714
+ end
715
+
716
+ module Rake::TaskManager
717
+ def initialize; end
718
+
719
+ def [](task_name, scopes = T.unsafe(nil)); end
720
+ def clear; end
721
+ def create_rule(*args, &block); end
722
+ def current_scope; end
723
+ def define_task(task_class, *args, &block); end
724
+ def enhance_with_matching_rule(task_name, level = T.unsafe(nil)); end
725
+ def generate_did_you_mean_suggestions(task_name); end
726
+ def generate_message_for_undefined_task(task_name); end
727
+ def in_namespace(name); end
728
+ def intern(task_class, task_name); end
729
+ def last_description; end
730
+ def last_description=(_); end
731
+ def lookup(task_name, initial_scope = T.unsafe(nil)); end
732
+ def resolve_args(args); end
733
+ def synthesize_file_task(task_name); end
734
+ def tasks; end
735
+ def tasks_in_scope(scope); end
736
+
737
+ private
738
+
739
+ def add_location(task); end
740
+ def attempt_rule(task_name, task_pattern, args, extensions, block, level); end
741
+ def find_location; end
742
+ def generate_name; end
743
+ def get_description(task); end
744
+ def lookup_in_scope(name, scope); end
745
+ def make_sources(task_name, task_pattern, extensions); end
746
+ def resolve_args_with_dependencies(args, hash); end
747
+ def resolve_args_without_dependencies(args); end
748
+ def trace_rule(level, message); end
749
+
750
+ class << self
751
+ def record_task_metadata; end
752
+ def record_task_metadata=(_); end
753
+ end
754
+ end
755
+
756
+ class Rake::ThreadHistoryDisplay
757
+ include(::Rake::PrivateReader)
758
+ extend(::Rake::PrivateReader::ClassMethods)
759
+
760
+ def initialize(stats); end
761
+
762
+ def show; end
763
+
764
+ private
765
+
766
+ def items; end
767
+ def rename(hash, key, renames); end
768
+ def stats; end
769
+ def threads; end
770
+ end
771
+
772
+ class Rake::ThreadPool
773
+ def initialize(thread_count); end
774
+
775
+ def future(*args, &block); end
776
+ def gather_history; end
777
+ def history; end
778
+ def join; end
779
+ def statistics; end
780
+
781
+ private
782
+
783
+ def __queue__; end
784
+ def process_queue_item; end
785
+ def safe_thread_count; end
786
+ def start_thread; end
787
+ def stat(event, data = T.unsafe(nil)); end
788
+ end
789
+
790
+ module Rake::TraceOutput
791
+ def trace_on(out, *strings); end
792
+ end
793
+
794
+ Rake::VERSION = T.let(T.unsafe(nil), String)
795
+
796
+ module Rake::Version
797
+ end
798
+
799
+ Rake::Version::BUILD = T.let(T.unsafe(nil), String)
800
+
801
+ Rake::Version::MAJOR = T.let(T.unsafe(nil), String)
802
+
803
+ Rake::Version::MINOR = T.let(T.unsafe(nil), String)
804
+
805
+ Rake::Version::NUMBERS = T.let(T.unsafe(nil), Array)
806
+
807
+ Rake::Version::OTHER = T.let(T.unsafe(nil), Array)
808
+
809
+ module Rake::Win32
810
+ class << self
811
+ def normalize(path); end
812
+ def win32_system_dir; end
813
+ def windows?; end
814
+ end
815
+ end
816
+
817
+ class Rake::Win32::Win32HomeError < ::RuntimeError
818
+ end
819
+
820
+ RakeFileUtils = Rake::FileUtilsExt
821
+
822
+ class String
823
+ include(::Comparable)
824
+ include(::Colorize::InstanceMethods)
825
+ include(::JSON::Ext::Generator::GeneratorMethods::String)
826
+ extend(::Colorize::ClassMethods)
827
+ extend(::JSON::Ext::Generator::GeneratorMethods::String::Extend)
828
+
829
+ def ext(newext = T.unsafe(nil)); end
830
+ def pathmap(spec = T.unsafe(nil), &block); end
831
+
832
+ protected
833
+
834
+ def pathmap_explode; end
835
+ def pathmap_partial(n); end
836
+ def pathmap_replace(patterns, &block); end
837
+ end
838
+
839
+ String::BLANK_RE = T.let(T.unsafe(nil), Regexp)
840
+
841
+ String::ENCODED_BLANKS = T.let(T.unsafe(nil), Concurrent::Map)