guard-srb 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.rubocop.yml +37 -0
- data/.tool-versions +1 -0
- data/CHANGELOG.md +5 -0
- data/CODE_OF_CONDUCT.md +84 -0
- data/Gemfile +14 -0
- data/Gemfile.lock +125 -0
- data/Guardfile +16 -0
- data/LICENSE.txt +21 -0
- data/README.md +92 -0
- data/Rakefile +18 -0
- data/lib/guard/srb/runner.rb +70 -0
- data/lib/guard/srb/templates/Guardfile +3 -0
- data/lib/guard/srb/version.rb +8 -0
- data/lib/guard/srb.rb +105 -0
- data/sorbet/config +5 -0
- data/sorbet/rbi/annotations/rainbow.rbi +269 -0
- data/sorbet/rbi/gems/ast@2.4.2.rbi +584 -0
- data/sorbet/rbi/gems/coderay@1.1.3.rbi +3437 -0
- data/sorbet/rbi/gems/diff-lcs@1.5.0.rbi +1079 -0
- data/sorbet/rbi/gems/ffi@1.15.5.rbi +8 -0
- data/sorbet/rbi/gems/formatador@1.1.0.rbi +8 -0
- data/sorbet/rbi/gems/guard-compat@1.2.1.rbi +103 -0
- data/sorbet/rbi/gems/guard-minitest@2.4.6.rbi +299 -0
- data/sorbet/rbi/gems/guard@2.16.2.rbi +2286 -0
- data/sorbet/rbi/gems/json@2.6.3.rbi +1541 -0
- data/sorbet/rbi/gems/listen@3.8.0.rbi +1181 -0
- data/sorbet/rbi/gems/lumberjack@1.2.8.rbi +1501 -0
- data/sorbet/rbi/gems/method_source@1.0.0.rbi +272 -0
- data/sorbet/rbi/gems/minitest@5.18.0.rbi +2354 -0
- data/sorbet/rbi/gems/mocha@2.0.2.rbi +3934 -0
- data/sorbet/rbi/gems/nenv@0.3.0.rbi +146 -0
- data/sorbet/rbi/gems/netrc@0.11.0.rbi +161 -0
- data/sorbet/rbi/gems/notiffany@0.1.3.rbi +1078 -0
- data/sorbet/rbi/gems/parallel@1.23.0.rbi +273 -0
- data/sorbet/rbi/gems/parser@3.2.2.1.rbi +9454 -0
- data/sorbet/rbi/gems/pry@0.14.2.rbi +10079 -0
- data/sorbet/rbi/gems/rainbow@3.1.1.rbi +402 -0
- data/sorbet/rbi/gems/rake@13.0.6.rbi +3119 -0
- data/sorbet/rbi/gems/rb-fsevent@0.11.2.rbi +8 -0
- data/sorbet/rbi/gems/rb-inotify@0.10.1.rbi +8 -0
- data/sorbet/rbi/gems/rbi@0.0.16.rbi +3049 -0
- data/sorbet/rbi/gems/regexp_parser@2.8.0.rbi +3765 -0
- data/sorbet/rbi/gems/rexml@3.2.5.rbi +4717 -0
- data/sorbet/rbi/gems/rubocop-ast@1.28.1.rbi +6967 -0
- data/sorbet/rbi/gems/rubocop@1.50.2.rbi +55367 -0
- data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +1317 -0
- data/sorbet/rbi/gems/ruby2_keywords@0.0.5.rbi +8 -0
- data/sorbet/rbi/gems/shellany@0.0.1.rbi +101 -0
- data/sorbet/rbi/gems/spoom@1.2.1.rbi +2536 -0
- data/sorbet/rbi/gems/tapioca@0.11.6.rbi +3246 -0
- data/sorbet/rbi/gems/thor@1.2.2.rbi +3965 -0
- data/sorbet/rbi/gems/unicode-display_width@2.4.2.rbi +65 -0
- data/sorbet/rbi/gems/unparser@0.6.7.rbi +4515 -0
- data/sorbet/rbi/gems/yard-sorbet@0.8.1.rbi +426 -0
- data/sorbet/rbi/gems/yard@0.9.34.rbi +17907 -0
- data/sorbet/rbi/todo.rbi +7 -0
- data/sorbet/tapioca/config.yml +13 -0
- data/sorbet/tapioca/require.rb +14 -0
- metadata +155 -0
@@ -0,0 +1,1181 @@
|
|
1
|
+
# typed: true
|
2
|
+
|
3
|
+
# DO NOT EDIT MANUALLY
|
4
|
+
# This is an autogenerated file for types exported from the `listen` gem.
|
5
|
+
# Please instead update this file by running `bin/tapioca gem listen`.
|
6
|
+
|
7
|
+
# This class just aggregates configuration object to avoid Listener specs
|
8
|
+
# from exploding with huge test setup blocks
|
9
|
+
#
|
10
|
+
# source://listen//lib/listen/logger.rb#3
|
11
|
+
module Listen
|
12
|
+
class << self
|
13
|
+
# source://listen//lib/listen/logger.rb#12
|
14
|
+
def logger; end
|
15
|
+
|
16
|
+
# Sets the attribute logger
|
17
|
+
#
|
18
|
+
# @param value the value to set the attribute logger to.
|
19
|
+
#
|
20
|
+
# source://listen//lib/listen/logger.rb#10
|
21
|
+
def logger=(_arg0); end
|
22
|
+
|
23
|
+
# This is used by the `listen` binary to handle Ctrl-C
|
24
|
+
#
|
25
|
+
# source://listen//lib/listen.rb#37
|
26
|
+
def stop; end
|
27
|
+
|
28
|
+
# Listens to file system modifications on a either single directory or
|
29
|
+
# multiple directories.
|
30
|
+
#
|
31
|
+
# @return [Listen::Listener] the listener
|
32
|
+
# @yield [modified, added, removed] the changed files
|
33
|
+
# @yieldparam modified [Array<String>] the list of modified files
|
34
|
+
# @yieldparam added [Array<String>] the list of added files
|
35
|
+
# @yieldparam removed [Array<String>] the list of removed files
|
36
|
+
#
|
37
|
+
# source://listen//lib/listen.rb#29
|
38
|
+
def to(*args, &block); end
|
39
|
+
|
40
|
+
private
|
41
|
+
|
42
|
+
# source://listen//lib/listen/logger.rb#18
|
43
|
+
def default_logger; end
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
# source://listen//lib/listen/adapter/base.rb#9
|
48
|
+
module Listen::Adapter
|
49
|
+
class << self
|
50
|
+
# source://listen//lib/listen/adapter.rb#17
|
51
|
+
def select(options = T.unsafe(nil)); end
|
52
|
+
|
53
|
+
private
|
54
|
+
|
55
|
+
# source://listen//lib/listen/adapter.rb#33
|
56
|
+
def _usable_adapter_class; end
|
57
|
+
|
58
|
+
# source://listen//lib/listen/adapter.rb#37
|
59
|
+
def _warn_polling_fallback(options); end
|
60
|
+
end
|
61
|
+
end
|
62
|
+
|
63
|
+
# source://listen//lib/listen/adapter/bsd.rb#9
|
64
|
+
class Listen::Adapter::BSD < ::Listen::Adapter::Base
|
65
|
+
private
|
66
|
+
|
67
|
+
# source://listen//lib/listen/adapter/bsd.rb#73
|
68
|
+
def _change(event_flags); end
|
69
|
+
|
70
|
+
# source://listen//lib/listen/adapter/bsd.rb#43
|
71
|
+
def _configure(directory, &callback); end
|
72
|
+
|
73
|
+
# source://listen//lib/listen/adapter/bsd.rb#82
|
74
|
+
def _event_path(event); end
|
75
|
+
|
76
|
+
# Quick rubocop workaround
|
77
|
+
#
|
78
|
+
# source://listen//lib/listen/adapter/bsd.rb#102
|
79
|
+
def _find(*paths, &block); end
|
80
|
+
|
81
|
+
# source://listen//lib/listen/adapter/bsd.rb#55
|
82
|
+
def _process_event(dir, event); end
|
83
|
+
|
84
|
+
# source://listen//lib/listen/adapter/bsd.rb#51
|
85
|
+
def _run; end
|
86
|
+
|
87
|
+
# source://listen//lib/listen/adapter/bsd.rb#95
|
88
|
+
def _watch_file(path, queue); end
|
89
|
+
|
90
|
+
# source://listen//lib/listen/adapter/bsd.rb#86
|
91
|
+
def _watch_for_new_file(event); end
|
92
|
+
|
93
|
+
class << self
|
94
|
+
# @return [Boolean]
|
95
|
+
#
|
96
|
+
# source://listen//lib/listen/adapter/bsd.rb#31
|
97
|
+
def usable?; end
|
98
|
+
end
|
99
|
+
end
|
100
|
+
|
101
|
+
# source://listen//lib/listen/adapter/bsd.rb#23
|
102
|
+
Listen::Adapter::BSD::BUNDLER_DECLARE_GEM = T.let(T.unsafe(nil), String)
|
103
|
+
|
104
|
+
# source://listen//lib/listen/adapter/bsd.rb#12
|
105
|
+
Listen::Adapter::BSD::DEFAULTS = T.let(T.unsafe(nil), Hash)
|
106
|
+
|
107
|
+
# source://listen//lib/listen/adapter/bsd.rb#10
|
108
|
+
Listen::Adapter::BSD::OS_REGEXP = T.let(T.unsafe(nil), Regexp)
|
109
|
+
|
110
|
+
# source://listen//lib/listen/adapter/base.rb#10
|
111
|
+
class Listen::Adapter::Base
|
112
|
+
# @return [Base] a new instance of Base
|
113
|
+
#
|
114
|
+
# source://listen//lib/listen/adapter/base.rb#16
|
115
|
+
def initialize(config); end
|
116
|
+
|
117
|
+
# Returns the value of attribute config.
|
118
|
+
#
|
119
|
+
# source://listen//lib/listen/adapter/base.rb#11
|
120
|
+
def config; end
|
121
|
+
|
122
|
+
# TODO: it's a separate method as a temporary workaround for tests
|
123
|
+
#
|
124
|
+
# source://listen//lib/listen/adapter/base.rb#33
|
125
|
+
def configure; end
|
126
|
+
|
127
|
+
# Returns the value of attribute options.
|
128
|
+
#
|
129
|
+
# source://listen//lib/listen/adapter/base.rb#11
|
130
|
+
def options; end
|
131
|
+
|
132
|
+
# source://listen//lib/listen/adapter/base.rb#65
|
133
|
+
def start; end
|
134
|
+
|
135
|
+
# @return [Boolean]
|
136
|
+
#
|
137
|
+
# source://listen//lib/listen/adapter/base.rb#61
|
138
|
+
def started?; end
|
139
|
+
|
140
|
+
# source://listen//lib/listen/adapter/base.rb#83
|
141
|
+
def stop; end
|
142
|
+
|
143
|
+
private
|
144
|
+
|
145
|
+
# source://listen//lib/listen/adapter/base.rb#111
|
146
|
+
def _log_exception(msg, caller_stack); end
|
147
|
+
|
148
|
+
# TODO: allow backend adapters to pass specific invalidation objects
|
149
|
+
# e.g. Darwin -> DirRescan, INotify -> MoveScan, etc.
|
150
|
+
#
|
151
|
+
# source://listen//lib/listen/adapter/base.rb#107
|
152
|
+
def _queue_change(type, dir, rel_path, options); end
|
153
|
+
|
154
|
+
# source://listen//lib/listen/adapter/base.rb#90
|
155
|
+
def _stop; end
|
156
|
+
|
157
|
+
# source://listen//lib/listen/adapter/base.rb#95
|
158
|
+
def _timed(title); end
|
159
|
+
|
160
|
+
class << self
|
161
|
+
# @return [Boolean]
|
162
|
+
#
|
163
|
+
# source://listen//lib/listen/adapter/base.rb#123
|
164
|
+
def usable?; end
|
165
|
+
end
|
166
|
+
end
|
167
|
+
|
168
|
+
# TODO: only used by tests
|
169
|
+
#
|
170
|
+
# source://listen//lib/listen/adapter/base.rb#14
|
171
|
+
Listen::Adapter::Base::DEFAULTS = T.let(T.unsafe(nil), Hash)
|
172
|
+
|
173
|
+
# source://listen//lib/listen/adapter/config.rb#7
|
174
|
+
class Listen::Adapter::Config
|
175
|
+
# @return [Config] a new instance of Config
|
176
|
+
#
|
177
|
+
# source://listen//lib/listen/adapter/config.rb#10
|
178
|
+
def initialize(directories, queue, silencer, adapter_options); end
|
179
|
+
|
180
|
+
# Returns the value of attribute adapter_options.
|
181
|
+
#
|
182
|
+
# source://listen//lib/listen/adapter/config.rb#8
|
183
|
+
def adapter_options; end
|
184
|
+
|
185
|
+
# Returns the value of attribute directories.
|
186
|
+
#
|
187
|
+
# source://listen//lib/listen/adapter/config.rb#8
|
188
|
+
def directories; end
|
189
|
+
|
190
|
+
# Returns the value of attribute queue.
|
191
|
+
#
|
192
|
+
# source://listen//lib/listen/adapter/config.rb#8
|
193
|
+
def queue; end
|
194
|
+
|
195
|
+
# Returns the value of attribute silencer.
|
196
|
+
#
|
197
|
+
# source://listen//lib/listen/adapter/config.rb#8
|
198
|
+
def silencer; end
|
199
|
+
end
|
200
|
+
|
201
|
+
# Adapter implementation for Mac OS X `FSEvents`.
|
202
|
+
#
|
203
|
+
# source://listen//lib/listen/adapter/darwin.rb#9
|
204
|
+
class Listen::Adapter::Darwin < ::Listen::Adapter::Base
|
205
|
+
private
|
206
|
+
|
207
|
+
# source://listen//lib/listen/adapter/darwin.rb#39
|
208
|
+
def _configure(dir, &callback); end
|
209
|
+
|
210
|
+
# source://listen//lib/listen/adapter/darwin.rb#52
|
211
|
+
def _process_changes(dirs); end
|
212
|
+
|
213
|
+
# source://listen//lib/listen/adapter/darwin.rb#64
|
214
|
+
def _process_event(dir, path); end
|
215
|
+
|
216
|
+
# source://listen//lib/listen/adapter/darwin.rb#43
|
217
|
+
def _run; end
|
218
|
+
|
219
|
+
# source://listen//lib/listen/adapter/darwin.rb#71
|
220
|
+
def _stop; end
|
221
|
+
|
222
|
+
class << self
|
223
|
+
# @return [Boolean]
|
224
|
+
#
|
225
|
+
# source://listen//lib/listen/adapter/darwin.rb#25
|
226
|
+
def usable?; end
|
227
|
+
end
|
228
|
+
end
|
229
|
+
|
230
|
+
# The default delay between checking for changes.
|
231
|
+
#
|
232
|
+
# source://listen//lib/listen/adapter/darwin.rb#13
|
233
|
+
Listen::Adapter::Darwin::DEFAULTS = T.let(T.unsafe(nil), Hash)
|
234
|
+
|
235
|
+
# source://listen//lib/listen/adapter/darwin.rb#15
|
236
|
+
Listen::Adapter::Darwin::INCOMPATIBLE_GEM_VERSION = T.let(T.unsafe(nil), String)
|
237
|
+
|
238
|
+
# source://listen//lib/listen/adapter/darwin.rb#10
|
239
|
+
Listen::Adapter::Darwin::OS_REGEXP = T.let(T.unsafe(nil), Regexp)
|
240
|
+
|
241
|
+
# @see https://github.com/nex3/rb-inotify
|
242
|
+
#
|
243
|
+
# source://listen//lib/listen/adapter/linux.rb#6
|
244
|
+
class Listen::Adapter::Linux < ::Listen::Adapter::Base
|
245
|
+
private
|
246
|
+
|
247
|
+
# source://listen//lib/listen/adapter/linux.rb#86
|
248
|
+
def _change(event_flags); end
|
249
|
+
|
250
|
+
# source://listen//lib/listen/adapter/linux.rb#27
|
251
|
+
def _configure(directory, &callback); end
|
252
|
+
|
253
|
+
# @return [Boolean]
|
254
|
+
#
|
255
|
+
# source://listen//lib/listen/adapter/linux.rb#97
|
256
|
+
def _dir_event?(event); end
|
257
|
+
|
258
|
+
# source://listen//lib/listen/adapter/linux.rb#42
|
259
|
+
def _process_event(dir, event); end
|
260
|
+
|
261
|
+
# source://listen//lib/listen/adapter/linux.rb#37
|
262
|
+
def _run; end
|
263
|
+
|
264
|
+
# @return [Boolean]
|
265
|
+
#
|
266
|
+
# source://listen//lib/listen/adapter/linux.rb#76
|
267
|
+
def _skip_event?(event); end
|
268
|
+
|
269
|
+
# source://listen//lib/listen/adapter/linux.rb#101
|
270
|
+
def _stop; end
|
271
|
+
end
|
272
|
+
|
273
|
+
# source://listen//lib/listen/adapter/linux.rb#9
|
274
|
+
Listen::Adapter::Linux::DEFAULTS = T.let(T.unsafe(nil), Hash)
|
275
|
+
|
276
|
+
# source://listen//lib/listen/adapter/linux.rb#7
|
277
|
+
Listen::Adapter::Linux::OS_REGEXP = T.let(T.unsafe(nil), Regexp)
|
278
|
+
|
279
|
+
# source://listen//lib/listen/adapter/linux.rb#24
|
280
|
+
Listen::Adapter::Linux::README_URL = T.let(T.unsafe(nil), String)
|
281
|
+
|
282
|
+
# source://listen//lib/listen/adapter.rb#12
|
283
|
+
Listen::Adapter::OPTIMIZED_ADAPTERS = T.let(T.unsafe(nil), Array)
|
284
|
+
|
285
|
+
# source://listen//lib/listen/adapter.rb#13
|
286
|
+
Listen::Adapter::POLLING_FALLBACK_MESSAGE = T.let(T.unsafe(nil), String)
|
287
|
+
|
288
|
+
# Polling Adapter that works cross-platform and
|
289
|
+
# has no dependencies. This is the adapter that
|
290
|
+
# uses the most CPU processing power and has higher
|
291
|
+
# file IO than the other implementations.
|
292
|
+
#
|
293
|
+
# source://listen//lib/listen/adapter/polling.rb#10
|
294
|
+
class Listen::Adapter::Polling < ::Listen::Adapter::Base
|
295
|
+
private
|
296
|
+
|
297
|
+
# source://listen//lib/listen/adapter/polling.rb#17
|
298
|
+
def _configure(_, &callback); end
|
299
|
+
|
300
|
+
# source://listen//lib/listen/adapter/polling.rb#35
|
301
|
+
def _process_event(dir, _); end
|
302
|
+
|
303
|
+
# source://listen//lib/listen/adapter/polling.rb#22
|
304
|
+
def _run; end
|
305
|
+
end
|
306
|
+
|
307
|
+
# source://listen//lib/listen/adapter/polling.rb#13
|
308
|
+
Listen::Adapter::Polling::DEFAULTS = T.let(T.unsafe(nil), Hash)
|
309
|
+
|
310
|
+
# match every OS
|
311
|
+
#
|
312
|
+
# source://listen//lib/listen/adapter/polling.rb#11
|
313
|
+
Listen::Adapter::Polling::OS_REGEXP = T.let(T.unsafe(nil), Regexp)
|
314
|
+
|
315
|
+
# Adapter implementation for Windows `wdm`.
|
316
|
+
#
|
317
|
+
# source://listen//lib/listen/adapter/windows.rb#7
|
318
|
+
class Listen::Adapter::Windows < ::Listen::Adapter::Base
|
319
|
+
private
|
320
|
+
|
321
|
+
# source://listen//lib/listen/adapter/windows.rb#87
|
322
|
+
def _change(type); end
|
323
|
+
|
324
|
+
# source://listen//lib/listen/adapter/windows.rb#29
|
325
|
+
def _configure(dir); end
|
326
|
+
|
327
|
+
# source://listen//lib/listen/adapter/windows.rb#51
|
328
|
+
def _process_event(dir, event); end
|
329
|
+
|
330
|
+
# source://listen//lib/listen/adapter/windows.rb#46
|
331
|
+
def _run; end
|
332
|
+
|
333
|
+
class << self
|
334
|
+
# @return [Boolean]
|
335
|
+
#
|
336
|
+
# source://listen//lib/listen/adapter/windows.rb#15
|
337
|
+
def usable?; end
|
338
|
+
end
|
339
|
+
end
|
340
|
+
|
341
|
+
# source://listen//lib/listen/adapter/windows.rb#10
|
342
|
+
Listen::Adapter::Windows::BUNDLER_DECLARE_GEM = T.let(T.unsafe(nil), String)
|
343
|
+
|
344
|
+
# source://listen//lib/listen/adapter/windows.rb#8
|
345
|
+
Listen::Adapter::Windows::OS_REGEXP = T.let(T.unsafe(nil), Regexp)
|
346
|
+
|
347
|
+
# source://listen//lib/listen/backend.rb#12
|
348
|
+
class Listen::Backend
|
349
|
+
extend ::Forwardable
|
350
|
+
|
351
|
+
# @return [Backend] a new instance of Backend
|
352
|
+
#
|
353
|
+
# source://listen//lib/listen/backend.rb#15
|
354
|
+
def initialize(directories, queue, silencer, config); end
|
355
|
+
|
356
|
+
# Returns the value of attribute min_delay_between_events.
|
357
|
+
#
|
358
|
+
# source://listen//lib/listen/backend.rb#34
|
359
|
+
def min_delay_between_events; end
|
360
|
+
|
361
|
+
# source://forwardable/1.3.1/forwardable.rb#226
|
362
|
+
def start(*args, &block); end
|
363
|
+
|
364
|
+
# source://forwardable/1.3.1/forwardable.rb#226
|
365
|
+
def stop(*args, &block); end
|
366
|
+
|
367
|
+
private
|
368
|
+
|
369
|
+
# Returns the value of attribute adapter.
|
370
|
+
#
|
371
|
+
# source://listen//lib/listen/backend.rb#38
|
372
|
+
def adapter; end
|
373
|
+
end
|
374
|
+
|
375
|
+
# TODO: rename to Snapshot
|
376
|
+
#
|
377
|
+
# source://listen//lib/listen/change.rb#8
|
378
|
+
class Listen::Change
|
379
|
+
# @return [Change] a new instance of Change
|
380
|
+
#
|
381
|
+
# source://listen//lib/listen/change.rb#27
|
382
|
+
def initialize(config, record); end
|
383
|
+
|
384
|
+
# Invalidate some part of the snapshot/record (dir, file, subtree, etc.)
|
385
|
+
#
|
386
|
+
# source://listen//lib/listen/change.rb#36
|
387
|
+
def invalidate(type, rel_path, options); end
|
388
|
+
|
389
|
+
# Returns the value of attribute record.
|
390
|
+
#
|
391
|
+
# source://listen//lib/listen/change.rb#25
|
392
|
+
def record; end
|
393
|
+
end
|
394
|
+
|
395
|
+
# TODO: test this class for coverage
|
396
|
+
#
|
397
|
+
# source://listen//lib/listen/change.rb#10
|
398
|
+
class Listen::Change::Config
|
399
|
+
# @return [Config] a new instance of Config
|
400
|
+
#
|
401
|
+
# source://listen//lib/listen/change.rb#11
|
402
|
+
def initialize(queue, silencer); end
|
403
|
+
|
404
|
+
# source://listen//lib/listen/change.rb#20
|
405
|
+
def queue(*args); end
|
406
|
+
|
407
|
+
# @return [Boolean]
|
408
|
+
#
|
409
|
+
# source://listen//lib/listen/change.rb#16
|
410
|
+
def silenced?(path, type); end
|
411
|
+
end
|
412
|
+
|
413
|
+
# TODO: refactor (turn it into a normal object, cache the stat, etc)
|
414
|
+
#
|
415
|
+
# source://listen//lib/listen/directory.rb#7
|
416
|
+
class Listen::Directory
|
417
|
+
class << self
|
418
|
+
# source://listen//lib/listen/directory.rb#62
|
419
|
+
def _async_changes(snapshot, path, previous, options); end
|
420
|
+
|
421
|
+
# source://listen//lib/listen/directory.rb#72
|
422
|
+
def _change(snapshot, type, path, options); end
|
423
|
+
|
424
|
+
# source://listen//lib/listen/directory.rb#82
|
425
|
+
def _children(path); end
|
426
|
+
|
427
|
+
# @return [Boolean]
|
428
|
+
#
|
429
|
+
# source://listen//lib/listen/directory.rb#56
|
430
|
+
def ascendant_of?(base, other); end
|
431
|
+
|
432
|
+
# source://listen//lib/listen/directory.rb#9
|
433
|
+
def scan(snapshot, rel_path, options); end
|
434
|
+
end
|
435
|
+
end
|
436
|
+
|
437
|
+
# source://listen//lib/listen/error.rb#6
|
438
|
+
class Listen::Error < ::RuntimeError; end
|
439
|
+
|
440
|
+
# source://listen//lib/listen/error.rb#9
|
441
|
+
class Listen::Error::INotifyMaxWatchesExceeded < ::Listen::Error; end
|
442
|
+
|
443
|
+
# source://listen//lib/listen/error.rb#7
|
444
|
+
class Listen::Error::NotStarted < ::Listen::Error; end
|
445
|
+
|
446
|
+
# source://listen//lib/listen/error.rb#8
|
447
|
+
class Listen::Error::SymlinkLoop < ::Listen::Error; end
|
448
|
+
|
449
|
+
# source://listen//lib/listen/event/processor.rb#6
|
450
|
+
module Listen::Event; end
|
451
|
+
|
452
|
+
# source://listen//lib/listen/event/config.rb#5
|
453
|
+
class Listen::Event::Config
|
454
|
+
# @return [Config] a new instance of Config
|
455
|
+
#
|
456
|
+
# source://listen//lib/listen/event/config.rb#8
|
457
|
+
def initialize(listener, event_queue, queue_optimizer, wait_for_delay, &block); end
|
458
|
+
|
459
|
+
# source://listen//lib/listen/event/config.rb#27
|
460
|
+
def call(*args); end
|
461
|
+
|
462
|
+
# @return [Boolean]
|
463
|
+
#
|
464
|
+
# source://listen//lib/listen/event/config.rb#31
|
465
|
+
def callable?; end
|
466
|
+
|
467
|
+
# Returns the value of attribute event_queue.
|
468
|
+
#
|
469
|
+
# source://listen//lib/listen/event/config.rb#6
|
470
|
+
def event_queue; end
|
471
|
+
|
472
|
+
# Returns the value of attribute listener.
|
473
|
+
#
|
474
|
+
# source://listen//lib/listen/event/config.rb#6
|
475
|
+
def listener; end
|
476
|
+
|
477
|
+
# Returns the value of attribute min_delay_between_events.
|
478
|
+
#
|
479
|
+
# source://listen//lib/listen/event/config.rb#6
|
480
|
+
def min_delay_between_events; end
|
481
|
+
|
482
|
+
# source://listen//lib/listen/event/config.rb#35
|
483
|
+
def optimize_changes(changes); end
|
484
|
+
|
485
|
+
# source://listen//lib/listen/event/config.rb#23
|
486
|
+
def sleep(seconds); end
|
487
|
+
end
|
488
|
+
|
489
|
+
# source://listen//lib/listen/event/loop.rb#12
|
490
|
+
class Listen::Event::Loop
|
491
|
+
include ::Listen::FSM
|
492
|
+
extend ::Listen::FSM::ClassMethods
|
493
|
+
|
494
|
+
# @return [Loop] a new instance of Loop
|
495
|
+
#
|
496
|
+
# source://listen//lib/listen/event/loop.rb#24
|
497
|
+
def initialize(config); end
|
498
|
+
|
499
|
+
# source://listen//lib/listen/event/loop.rb#62
|
500
|
+
def pause; end
|
501
|
+
|
502
|
+
# source://listen//lib/listen/event/loop.rb#44
|
503
|
+
def start; end
|
504
|
+
|
505
|
+
# @return [Boolean]
|
506
|
+
#
|
507
|
+
# source://listen//lib/listen/event/loop.rb#37
|
508
|
+
def started?; end
|
509
|
+
|
510
|
+
# source://listen//lib/listen/event/loop.rb#67
|
511
|
+
def stop; end
|
512
|
+
|
513
|
+
# @return [Boolean]
|
514
|
+
#
|
515
|
+
# source://listen//lib/listen/event/loop.rb#74
|
516
|
+
def stopped?; end
|
517
|
+
|
518
|
+
# source://listen//lib/listen/event/loop.rb#31
|
519
|
+
def wakeup_on_event; end
|
520
|
+
|
521
|
+
private
|
522
|
+
|
523
|
+
# source://listen//lib/listen/event/loop.rb#80
|
524
|
+
def _process_changes; end
|
525
|
+
|
526
|
+
# source://listen//lib/listen/event/loop.rb#88
|
527
|
+
def _wakeup(reason); end
|
528
|
+
end
|
529
|
+
|
530
|
+
# source://listen//lib/listen/event/loop.rb#15
|
531
|
+
Listen::Event::Loop::Error = Listen::Error
|
532
|
+
|
533
|
+
# source://listen//lib/listen/event/loop.rb#41
|
534
|
+
Listen::Event::Loop::MAX_STARTUP_SECONDS = T.let(T.unsafe(nil), Float)
|
535
|
+
|
536
|
+
# for backward compatibility
|
537
|
+
#
|
538
|
+
# source://listen//lib/listen/event/loop.rb#16
|
539
|
+
Listen::Event::Loop::NotStarted = Listen::Error::NotStarted
|
540
|
+
|
541
|
+
# source://listen//lib/listen/event/processor.rb#7
|
542
|
+
class Listen::Event::Processor
|
543
|
+
# @return [Processor] a new instance of Processor
|
544
|
+
#
|
545
|
+
# source://listen//lib/listen/event/processor.rb#8
|
546
|
+
def initialize(config, reasons); end
|
547
|
+
|
548
|
+
# TODO: implement this properly instead of checking the state at arbitrary
|
549
|
+
# points in time
|
550
|
+
#
|
551
|
+
# source://listen//lib/listen/event/processor.rb#17
|
552
|
+
def loop_for(latency); end
|
553
|
+
|
554
|
+
private
|
555
|
+
|
556
|
+
# source://listen//lib/listen/event/processor.rb#55
|
557
|
+
def _check_stopped; end
|
558
|
+
|
559
|
+
# source://listen//lib/listen/event/processor.rb#82
|
560
|
+
def _deadline; end
|
561
|
+
|
562
|
+
# source://listen//lib/listen/event/processor.rb#94
|
563
|
+
def _flush_wakeup_reasons; end
|
564
|
+
|
565
|
+
# for easier testing without sleep loop
|
566
|
+
#
|
567
|
+
# source://listen//lib/listen/event/processor.rb#102
|
568
|
+
def _process_changes(event); end
|
569
|
+
|
570
|
+
# source://listen//lib/listen/event/processor.rb#74
|
571
|
+
def _remember_time_of_first_unprocessed_event; end
|
572
|
+
|
573
|
+
# source://listen//lib/listen/event/processor.rb#78
|
574
|
+
def _reset_no_unprocessed_events; end
|
575
|
+
|
576
|
+
# source://listen//lib/listen/event/processor.rb#62
|
577
|
+
def _sleep(seconds); end
|
578
|
+
|
579
|
+
# blocks until event is popped
|
580
|
+
# returns the event or `nil` when the event_queue is closed
|
581
|
+
#
|
582
|
+
# source://listen//lib/listen/event/processor.rb#88
|
583
|
+
def _wait_until_events; end
|
584
|
+
|
585
|
+
# source://listen//lib/listen/event/processor.rb#36
|
586
|
+
def _wait_until_events_calm_down; end
|
587
|
+
|
588
|
+
# source://listen//lib/listen/event/processor.rb#51
|
589
|
+
def _wait_until_no_longer_paused; end
|
590
|
+
|
591
|
+
# Returns the value of attribute config.
|
592
|
+
#
|
593
|
+
# source://listen//lib/listen/event/processor.rb#123
|
594
|
+
def config; end
|
595
|
+
end
|
596
|
+
|
597
|
+
# source://listen//lib/listen/event/processor.rb#33
|
598
|
+
class Listen::Event::Processor::Stopped < ::RuntimeError; end
|
599
|
+
|
600
|
+
# source://listen//lib/listen/event/queue.rb#9
|
601
|
+
class Listen::Event::Queue
|
602
|
+
extend ::Forwardable
|
603
|
+
|
604
|
+
# @return [Queue] a new instance of Queue
|
605
|
+
#
|
606
|
+
# source://listen//lib/listen/event/queue.rb#22
|
607
|
+
def initialize(config); end
|
608
|
+
|
609
|
+
# source://listen//lib/listen/event/queue.rb#27
|
610
|
+
def <<(args); end
|
611
|
+
|
612
|
+
# source://forwardable/1.3.1/forwardable.rb#226
|
613
|
+
def close(*args, &block); end
|
614
|
+
|
615
|
+
# source://forwardable/1.3.1/forwardable.rb#226
|
616
|
+
def empty?(*args, &block); end
|
617
|
+
|
618
|
+
# source://forwardable/1.3.1/forwardable.rb#226
|
619
|
+
def pop(*args, &block); end
|
620
|
+
|
621
|
+
private
|
622
|
+
|
623
|
+
# source://listen//lib/listen/event/queue.rb#47
|
624
|
+
def _safe_relative_from_cwd(dir); end
|
625
|
+
end
|
626
|
+
|
627
|
+
# source://listen//lib/listen/event/queue.rb#12
|
628
|
+
class Listen::Event::Queue::Config
|
629
|
+
# @return [Config] a new instance of Config
|
630
|
+
#
|
631
|
+
# source://listen//lib/listen/event/queue.rb#13
|
632
|
+
def initialize(relative); end
|
633
|
+
|
634
|
+
# @return [Boolean]
|
635
|
+
#
|
636
|
+
# source://listen//lib/listen/event/queue.rb#17
|
637
|
+
def relative?; end
|
638
|
+
end
|
639
|
+
|
640
|
+
# source://listen//lib/listen/fsm.rb#8
|
641
|
+
module Listen::FSM
|
642
|
+
mixes_in_class_methods ::Listen::FSM::ClassMethods
|
643
|
+
|
644
|
+
# Note: including classes must call initialize_fsm from their initialize method.
|
645
|
+
#
|
646
|
+
# source://listen//lib/listen/fsm.rb#42
|
647
|
+
def initialize_fsm; end
|
648
|
+
|
649
|
+
# Current state of the FSM, stored as a symbol
|
650
|
+
#
|
651
|
+
# source://listen//lib/listen/fsm.rb#50
|
652
|
+
def state; end
|
653
|
+
|
654
|
+
# checks for one of the given states to wait for
|
655
|
+
# if not already, waits for a state change (up to timeout seconds--`nil` means infinite)
|
656
|
+
# returns truthy iff the transition to one of the desired state has occurred
|
657
|
+
#
|
658
|
+
# source://listen//lib/listen/fsm.rb#55
|
659
|
+
def wait_for_state(*wait_for_states, timeout: T.unsafe(nil)); end
|
660
|
+
|
661
|
+
private
|
662
|
+
|
663
|
+
# source://listen//lib/listen/fsm.rb#108
|
664
|
+
def current_state; end
|
665
|
+
|
666
|
+
# source://listen//lib/listen/fsm.rb#69
|
667
|
+
def transition(new_state_name); end
|
668
|
+
|
669
|
+
# Low-level, immediate state transition with no checks or callbacks.
|
670
|
+
#
|
671
|
+
# source://listen//lib/listen/fsm.rb#77
|
672
|
+
def transition!(new_state_name); end
|
673
|
+
|
674
|
+
# source://listen//lib/listen/fsm.rb#103
|
675
|
+
def transition_with_callbacks!(new_state); end
|
676
|
+
|
677
|
+
# source://listen//lib/listen/fsm.rb#87
|
678
|
+
def validate_and_sanitize_new_state(new_state_name); end
|
679
|
+
|
680
|
+
class << self
|
681
|
+
# Included hook to extend class methods
|
682
|
+
#
|
683
|
+
# source://listen//lib/listen/fsm.rb#10
|
684
|
+
def included(klass); end
|
685
|
+
end
|
686
|
+
end
|
687
|
+
|
688
|
+
# source://listen//lib/listen/fsm.rb#14
|
689
|
+
module Listen::FSM::ClassMethods
|
690
|
+
# Obtain or set the start state
|
691
|
+
# Passing a state name sets the start state
|
692
|
+
#
|
693
|
+
# source://listen//lib/listen/fsm.rb#17
|
694
|
+
def start_state(new_start_state = T.unsafe(nil)); end
|
695
|
+
|
696
|
+
# Declare an FSM state and optionally provide a callback block to fire on state entry
|
697
|
+
# Options:
|
698
|
+
# * to: a state or array of states this state can transition to
|
699
|
+
#
|
700
|
+
# source://listen//lib/listen/fsm.rb#35
|
701
|
+
def state(state_name, to: T.unsafe(nil), &block); end
|
702
|
+
|
703
|
+
# The valid states for this FSM, as a hash with state name symbols as keys and State objects as values.
|
704
|
+
#
|
705
|
+
# source://listen//lib/listen/fsm.rb#28
|
706
|
+
def states; end
|
707
|
+
end
|
708
|
+
|
709
|
+
# source://listen//lib/listen/fsm.rb#112
|
710
|
+
class Listen::FSM::State
|
711
|
+
# @return [State] a new instance of State
|
712
|
+
#
|
713
|
+
# source://listen//lib/listen/fsm.rb#115
|
714
|
+
def initialize(name, transitions, &block); end
|
715
|
+
|
716
|
+
# source://listen//lib/listen/fsm.rb#123
|
717
|
+
def call(obj); end
|
718
|
+
|
719
|
+
# Returns the value of attribute name.
|
720
|
+
#
|
721
|
+
# source://listen//lib/listen/fsm.rb#113
|
722
|
+
def name; end
|
723
|
+
|
724
|
+
# Returns the value of attribute transitions.
|
725
|
+
#
|
726
|
+
# source://listen//lib/listen/fsm.rb#113
|
727
|
+
def transitions; end
|
728
|
+
|
729
|
+
# @return [Boolean]
|
730
|
+
#
|
731
|
+
# source://listen//lib/listen/fsm.rb#127
|
732
|
+
def valid_transition?(new_state); end
|
733
|
+
end
|
734
|
+
|
735
|
+
# source://listen//lib/listen/file.rb#6
|
736
|
+
class Listen::File
|
737
|
+
class << self
|
738
|
+
# source://listen//lib/listen/file.rb#10
|
739
|
+
def change(record, rel_path); end
|
740
|
+
|
741
|
+
# @return [Boolean]
|
742
|
+
#
|
743
|
+
# source://listen//lib/listen/file.rb#86
|
744
|
+
def inaccurate_mac_time?(stat); end
|
745
|
+
end
|
746
|
+
end
|
747
|
+
|
748
|
+
# source://listen//lib/listen/listener/config.rb#4
|
749
|
+
class Listen::Listener
|
750
|
+
include ::Listen::FSM
|
751
|
+
extend ::Listen::FSM::ClassMethods
|
752
|
+
|
753
|
+
# Initializes the directories listener.
|
754
|
+
#
|
755
|
+
#
|
756
|
+
# @param directory [String] the directories to listen to
|
757
|
+
# @param options [Hash] the listen options (see Listen::Listener::Options)
|
758
|
+
# @return [Listener] a new instance of Listener
|
759
|
+
# @yield [modified, added, removed] the changed files
|
760
|
+
# @yieldparam modified [Array<String>] the list of modified files
|
761
|
+
# @yieldparam added [Array<String>] the list of added files
|
762
|
+
# @yieldparam removed [Array<String>] the list of removed files
|
763
|
+
#
|
764
|
+
# source://listen//lib/listen/listener.rb#37
|
765
|
+
def initialize(*dirs, &block); end
|
766
|
+
|
767
|
+
# source://listen//lib/listen/listener.rb#124
|
768
|
+
def ignore(regexps); end
|
769
|
+
|
770
|
+
# source://listen//lib/listen/listener.rb#128
|
771
|
+
def ignore!(regexps); end
|
772
|
+
|
773
|
+
# source://listen//lib/listen/listener.rb#132
|
774
|
+
def only(regexps); end
|
775
|
+
|
776
|
+
# Stops invoking callbacks (messages pile up)
|
777
|
+
#
|
778
|
+
# source://listen//lib/listen/listener.rb#107
|
779
|
+
def pause; end
|
780
|
+
|
781
|
+
# @return [Boolean]
|
782
|
+
#
|
783
|
+
# source://listen//lib/listen/listener.rb#116
|
784
|
+
def paused?; end
|
785
|
+
|
786
|
+
# processing means callbacks are called
|
787
|
+
#
|
788
|
+
# @return [Boolean]
|
789
|
+
#
|
790
|
+
# source://listen//lib/listen/listener.rb#112
|
791
|
+
def processing?; end
|
792
|
+
|
793
|
+
# Starts processing events and starts adapters
|
794
|
+
# or resumes invoking callbacks if paused
|
795
|
+
#
|
796
|
+
# source://listen//lib/listen/listener.rb#89
|
797
|
+
def start; end
|
798
|
+
|
799
|
+
# Stops both listening for events and processing them
|
800
|
+
#
|
801
|
+
# source://listen//lib/listen/listener.rb#102
|
802
|
+
def stop; end
|
803
|
+
|
804
|
+
# @return [Boolean]
|
805
|
+
#
|
806
|
+
# source://listen//lib/listen/listener.rb#120
|
807
|
+
def stopped?; end
|
808
|
+
end
|
809
|
+
|
810
|
+
# source://listen//lib/listen/listener/config.rb#5
|
811
|
+
class Listen::Listener::Config
|
812
|
+
# @return [Config] a new instance of Config
|
813
|
+
#
|
814
|
+
# source://listen//lib/listen/listener/config.rb#17
|
815
|
+
def initialize(opts); end
|
816
|
+
|
817
|
+
# source://listen//lib/listen/listener/config.rb#30
|
818
|
+
def adapter_instance_options(klass); end
|
819
|
+
|
820
|
+
# source://listen//lib/listen/listener/config.rb#35
|
821
|
+
def adapter_select_options; end
|
822
|
+
|
823
|
+
# Returns the value of attribute min_delay_between_events.
|
824
|
+
#
|
825
|
+
# source://listen//lib/listen/listener/config.rb#28
|
826
|
+
def min_delay_between_events; end
|
827
|
+
|
828
|
+
# @return [Boolean]
|
829
|
+
#
|
830
|
+
# source://listen//lib/listen/listener/config.rb#24
|
831
|
+
def relative?; end
|
832
|
+
|
833
|
+
# Returns the value of attribute silencer_rules.
|
834
|
+
#
|
835
|
+
# source://listen//lib/listen/listener/config.rb#28
|
836
|
+
def silencer_rules; end
|
837
|
+
end
|
838
|
+
|
839
|
+
# source://listen//lib/listen/listener/config.rb#6
|
840
|
+
Listen::Listener::Config::DEFAULTS = T.let(T.unsafe(nil), Hash)
|
841
|
+
|
842
|
+
# source://listen//lib/listen/monotonic_time.rb#4
|
843
|
+
module Listen::MonotonicTime
|
844
|
+
class << self
|
845
|
+
# source://listen//lib/listen/monotonic_time.rb#8
|
846
|
+
def now; end
|
847
|
+
end
|
848
|
+
end
|
849
|
+
|
850
|
+
# source://listen//lib/listen/options.rb#4
|
851
|
+
class Listen::Options
|
852
|
+
# @return [Options] a new instance of Options
|
853
|
+
#
|
854
|
+
# source://listen//lib/listen/options.rb#5
|
855
|
+
def initialize(opts, defaults); end
|
856
|
+
|
857
|
+
# source://listen//lib/listen/options.rb#20
|
858
|
+
def method_missing(name, *_); end
|
859
|
+
|
860
|
+
private
|
861
|
+
|
862
|
+
# @return [Boolean]
|
863
|
+
#
|
864
|
+
# source://listen//lib/listen/options.rb#16
|
865
|
+
def respond_to_missing?(name, *_); end
|
866
|
+
end
|
867
|
+
|
868
|
+
# source://listen//lib/listen/queue_optimizer.rb#4
|
869
|
+
class Listen::QueueOptimizer
|
870
|
+
# @return [QueueOptimizer] a new instance of QueueOptimizer
|
871
|
+
#
|
872
|
+
# source://listen//lib/listen/queue_optimizer.rb#32
|
873
|
+
def initialize(config); end
|
874
|
+
|
875
|
+
# source://listen//lib/listen/queue_optimizer.rb#24
|
876
|
+
def smoosh_changes(changes); end
|
877
|
+
|
878
|
+
private
|
879
|
+
|
880
|
+
# source://listen//lib/listen/queue_optimizer.rb#69
|
881
|
+
def _calculate_add_remove_difference(actions, path, default_if_exists); end
|
882
|
+
|
883
|
+
# source://listen//lib/listen/queue_optimizer.rb#61
|
884
|
+
def _logical_action_for(path, actions); end
|
885
|
+
|
886
|
+
# remove extraneous rb-inotify events, keeping them only if it's a possible
|
887
|
+
# editor rename() call (e.g. Kate and Sublime)
|
888
|
+
#
|
889
|
+
# source://listen//lib/listen/queue_optimizer.rb#91
|
890
|
+
def _reinterpret_related_changes(cookies); end
|
891
|
+
|
892
|
+
# groups changes into the expected structure expected by
|
893
|
+
# clients
|
894
|
+
#
|
895
|
+
# source://listen//lib/listen/queue_optimizer.rb#42
|
896
|
+
def _squash_changes(changes); end
|
897
|
+
|
898
|
+
# Returns the value of attribute config.
|
899
|
+
#
|
900
|
+
# source://listen//lib/listen/queue_optimizer.rb#38
|
901
|
+
def config; end
|
902
|
+
|
903
|
+
# @return [Boolean]
|
904
|
+
#
|
905
|
+
# source://listen//lib/listen/queue_optimizer.rb#107
|
906
|
+
def editor_modified?(changes); end
|
907
|
+
end
|
908
|
+
|
909
|
+
# source://listen//lib/listen/queue_optimizer.rb#5
|
910
|
+
class Listen::QueueOptimizer::Config
|
911
|
+
# @return [Config] a new instance of Config
|
912
|
+
#
|
913
|
+
# source://listen//lib/listen/queue_optimizer.rb#6
|
914
|
+
def initialize(adapter_class, silencer); end
|
915
|
+
|
916
|
+
# source://listen//lib/listen/queue_optimizer.rb#19
|
917
|
+
def debug(*args, &block); end
|
918
|
+
|
919
|
+
# @return [Boolean]
|
920
|
+
#
|
921
|
+
# source://listen//lib/listen/queue_optimizer.rb#11
|
922
|
+
def exist?(path); end
|
923
|
+
|
924
|
+
# @return [Boolean]
|
925
|
+
#
|
926
|
+
# source://listen//lib/listen/queue_optimizer.rb#15
|
927
|
+
def silenced?(path, type); end
|
928
|
+
end
|
929
|
+
|
930
|
+
# @private api
|
931
|
+
#
|
932
|
+
# source://listen//lib/listen/record/entry.rb#5
|
933
|
+
class Listen::Record
|
934
|
+
# @return [Record] a new instance of Record
|
935
|
+
#
|
936
|
+
# source://listen//lib/listen/record.rb#14
|
937
|
+
def initialize(directory, silencer); end
|
938
|
+
|
939
|
+
# source://listen//lib/listen/record.rb#20
|
940
|
+
def add_dir(rel_path); end
|
941
|
+
|
942
|
+
# source://listen//lib/listen/record.rb#62
|
943
|
+
def build; end
|
944
|
+
|
945
|
+
# source://listen//lib/listen/record.rb#46
|
946
|
+
def dir_entries(rel_path); end
|
947
|
+
|
948
|
+
# source://listen//lib/listen/record.rb#36
|
949
|
+
def file_data(rel_path); end
|
950
|
+
|
951
|
+
# TODO: one Record object per watched directory?
|
952
|
+
# TODO: deprecate
|
953
|
+
#
|
954
|
+
# source://listen//lib/listen/record.rb#12
|
955
|
+
def root; end
|
956
|
+
|
957
|
+
# source://listen//lib/listen/record.rb#31
|
958
|
+
def unset_path(rel_path); end
|
959
|
+
|
960
|
+
# source://listen//lib/listen/record.rb#26
|
961
|
+
def update_file(rel_path, data); end
|
962
|
+
|
963
|
+
private
|
964
|
+
|
965
|
+
# source://listen//lib/listen/record.rb#103
|
966
|
+
def _fast_build_dir(remaining, symlink_detector); end
|
967
|
+
|
968
|
+
# source://listen//lib/listen/record.rb#117
|
969
|
+
def _fast_try_file(entry); end
|
970
|
+
|
971
|
+
# source://listen//lib/listen/record.rb#91
|
972
|
+
def _fast_unset_path(dirname, basename); end
|
973
|
+
|
974
|
+
# source://listen//lib/listen/record.rb#83
|
975
|
+
def _fast_update_file(dirname, basename, data); end
|
976
|
+
|
977
|
+
# @return [Boolean]
|
978
|
+
#
|
979
|
+
# source://listen//lib/listen/record.rb#75
|
980
|
+
def empty_dirname?(dirname); end
|
981
|
+
|
982
|
+
# source://listen//lib/listen/record.rb#79
|
983
|
+
def reset_tree; end
|
984
|
+
end
|
985
|
+
|
986
|
+
# Represents a directory entry (dir or file)
|
987
|
+
#
|
988
|
+
# source://listen//lib/listen/record/entry.rb#7
|
989
|
+
class Listen::Record::Entry
|
990
|
+
# file: "/home/me/watched_dir", "app/models", "foo.rb"
|
991
|
+
# dir, "/home/me/watched_dir", "."
|
992
|
+
#
|
993
|
+
# @return [Entry] a new instance of Entry
|
994
|
+
#
|
995
|
+
# source://listen//lib/listen/record/entry.rb#10
|
996
|
+
def initialize(root, relative, name = T.unsafe(nil)); end
|
997
|
+
|
998
|
+
# source://listen//lib/listen/record/entry.rb#18
|
999
|
+
def children; end
|
1000
|
+
|
1001
|
+
# source://listen//lib/listen/record/entry.rb#25
|
1002
|
+
def meta; end
|
1003
|
+
|
1004
|
+
# Returns the value of attribute name.
|
1005
|
+
#
|
1006
|
+
# source://listen//lib/listen/record/entry.rb#16
|
1007
|
+
def name; end
|
1008
|
+
|
1009
|
+
# source://listen//lib/listen/record/entry.rb#43
|
1010
|
+
def real_path; end
|
1011
|
+
|
1012
|
+
# record hash is e.g.
|
1013
|
+
# if @record["/home/me/watched_dir"]["project/app/models"]["foo.rb"]
|
1014
|
+
# if @record["/home/me/watched_dir"]["project/app"]["models"]
|
1015
|
+
# record_dir_key is "project/app/models"
|
1016
|
+
#
|
1017
|
+
# source://listen//lib/listen/record/entry.rb#34
|
1018
|
+
def record_dir_key; end
|
1019
|
+
|
1020
|
+
# Returns the value of attribute relative.
|
1021
|
+
#
|
1022
|
+
# source://listen//lib/listen/record/entry.rb#16
|
1023
|
+
def relative; end
|
1024
|
+
|
1025
|
+
# Returns the value of attribute root.
|
1026
|
+
#
|
1027
|
+
# source://listen//lib/listen/record/entry.rb#16
|
1028
|
+
def root; end
|
1029
|
+
|
1030
|
+
# source://listen//lib/listen/record/entry.rb#38
|
1031
|
+
def sys_path; end
|
1032
|
+
|
1033
|
+
private
|
1034
|
+
|
1035
|
+
# @raise [Errno::ENOTDIR]
|
1036
|
+
#
|
1037
|
+
# source://listen//lib/listen/record/entry.rb#54
|
1038
|
+
def _entries(dir); end
|
1039
|
+
|
1040
|
+
# source://listen//lib/listen/record/entry.rb#49
|
1041
|
+
def _join; end
|
1042
|
+
end
|
1043
|
+
|
1044
|
+
# source://listen//lib/listen/record/symlink_detector.rb#9
|
1045
|
+
class Listen::Record::SymlinkDetector
|
1046
|
+
# @return [SymlinkDetector] a new instance of SymlinkDetector
|
1047
|
+
#
|
1048
|
+
# source://listen//lib/listen/record/symlink_detector.rb#24
|
1049
|
+
def initialize; end
|
1050
|
+
|
1051
|
+
# source://listen//lib/listen/record/symlink_detector.rb#28
|
1052
|
+
def verify_unwatched!(entry); end
|
1053
|
+
|
1054
|
+
private
|
1055
|
+
|
1056
|
+
# @raise [::Listen::Error::SymlinkLoop]
|
1057
|
+
#
|
1058
|
+
# source://listen//lib/listen/record/symlink_detector.rb#35
|
1059
|
+
def _fail(symlinked, real_path); end
|
1060
|
+
end
|
1061
|
+
|
1062
|
+
# for backward compatibility
|
1063
|
+
#
|
1064
|
+
# source://listen//lib/listen/record/symlink_detector.rb#22
|
1065
|
+
Listen::Record::SymlinkDetector::Error = Listen::Error
|
1066
|
+
|
1067
|
+
# source://listen//lib/listen/record/symlink_detector.rb#10
|
1068
|
+
Listen::Record::SymlinkDetector::README_URL = T.let(T.unsafe(nil), String)
|
1069
|
+
|
1070
|
+
# source://listen//lib/listen/record/symlink_detector.rb#12
|
1071
|
+
Listen::Record::SymlinkDetector::SYMLINK_LOOP_ERROR = T.let(T.unsafe(nil), String)
|
1072
|
+
|
1073
|
+
# source://listen//lib/listen/silencer.rb#4
|
1074
|
+
class Listen::Silencer
|
1075
|
+
# @return [Silencer] a new instance of Silencer
|
1076
|
+
#
|
1077
|
+
# source://listen//lib/listen/silencer.rb#67
|
1078
|
+
def initialize(**options); end
|
1079
|
+
|
1080
|
+
# TODO: deprecate this mutator
|
1081
|
+
#
|
1082
|
+
# source://listen//lib/listen/silencer.rb#72
|
1083
|
+
def configure(options); end
|
1084
|
+
|
1085
|
+
# TODO: deprecate these mutators; use attr_reader instead
|
1086
|
+
#
|
1087
|
+
# source://listen//lib/listen/silencer.rb#65
|
1088
|
+
def ignore_patterns; end
|
1089
|
+
|
1090
|
+
# TODO: deprecate these mutators; use attr_reader instead
|
1091
|
+
#
|
1092
|
+
# source://listen//lib/listen/silencer.rb#65
|
1093
|
+
def ignore_patterns=(_arg0); end
|
1094
|
+
|
1095
|
+
# TODO: deprecate these mutators; use attr_reader instead
|
1096
|
+
#
|
1097
|
+
# source://listen//lib/listen/silencer.rb#65
|
1098
|
+
def only_patterns; end
|
1099
|
+
|
1100
|
+
# TODO: deprecate these mutators; use attr_reader instead
|
1101
|
+
#
|
1102
|
+
# source://listen//lib/listen/silencer.rb#65
|
1103
|
+
def only_patterns=(_arg0); end
|
1104
|
+
|
1105
|
+
# @return [Boolean]
|
1106
|
+
#
|
1107
|
+
# source://listen//lib/listen/silencer.rb#77
|
1108
|
+
def silenced?(relative_path, type); end
|
1109
|
+
|
1110
|
+
private
|
1111
|
+
|
1112
|
+
# @return [Boolean]
|
1113
|
+
#
|
1114
|
+
# source://listen//lib/listen/silencer.rb#85
|
1115
|
+
def _ignore?(path); end
|
1116
|
+
|
1117
|
+
# source://listen//lib/listen/silencer.rb#93
|
1118
|
+
def _init_ignores(ignores, overrides); end
|
1119
|
+
|
1120
|
+
# @return [Boolean]
|
1121
|
+
#
|
1122
|
+
# source://listen//lib/listen/silencer.rb#89
|
1123
|
+
def _only?(path); end
|
1124
|
+
end
|
1125
|
+
|
1126
|
+
# source://listen//lib/listen/silencer/controller.rb#5
|
1127
|
+
class Listen::Silencer::Controller
|
1128
|
+
# @return [Controller] a new instance of Controller
|
1129
|
+
#
|
1130
|
+
# source://listen//lib/listen/silencer/controller.rb#6
|
1131
|
+
def initialize(silencer, default_options); end
|
1132
|
+
|
1133
|
+
# source://listen//lib/listen/silencer/controller.rb#19
|
1134
|
+
def append_ignores(*regexps); end
|
1135
|
+
|
1136
|
+
# source://listen//lib/listen/silencer/controller.rb#24
|
1137
|
+
def replace_with_bang_ignores(regexps); end
|
1138
|
+
|
1139
|
+
# source://listen//lib/listen/silencer/controller.rb#28
|
1140
|
+
def replace_with_only(regexps); end
|
1141
|
+
|
1142
|
+
private
|
1143
|
+
|
1144
|
+
# source://listen//lib/listen/silencer/controller.rb#34
|
1145
|
+
def _reconfigure_silencer(extra_options); end
|
1146
|
+
end
|
1147
|
+
|
1148
|
+
# The default list of files that get ignored.
|
1149
|
+
#
|
1150
|
+
# source://listen//lib/listen/silencer.rb#24
|
1151
|
+
Listen::Silencer::DEFAULT_IGNORED_EXTENSIONS = T.let(T.unsafe(nil), Regexp)
|
1152
|
+
|
1153
|
+
# The default list of directories that get ignored.
|
1154
|
+
#
|
1155
|
+
# source://listen//lib/listen/silencer.rb#6
|
1156
|
+
Listen::Silencer::DEFAULT_IGNORED_FILES = T.let(T.unsafe(nil), Regexp)
|
1157
|
+
|
1158
|
+
# source://listen//lib/listen/thread.rb#8
|
1159
|
+
module Listen::Thread
|
1160
|
+
class << self
|
1161
|
+
# Creates a new thread with the given name.
|
1162
|
+
# Any exceptions raised by the thread will be logged with the thread name and complete backtrace.
|
1163
|
+
#
|
1164
|
+
# source://listen//lib/listen/thread.rb#13
|
1165
|
+
def new(name, &block); end
|
1166
|
+
|
1167
|
+
# source://listen//lib/listen/thread.rb#25
|
1168
|
+
def rescue_and_log(method_name, *args, caller_stack: T.unsafe(nil)); end
|
1169
|
+
|
1170
|
+
private
|
1171
|
+
|
1172
|
+
# source://listen//lib/listen/thread.rb#43
|
1173
|
+
def _exception_with_causes(exception); end
|
1174
|
+
|
1175
|
+
# source://listen//lib/listen/thread.rb#33
|
1176
|
+
def _log_exception(exception, thread_name, caller_stack: T.unsafe(nil)); end
|
1177
|
+
end
|
1178
|
+
end
|
1179
|
+
|
1180
|
+
# source://listen//lib/listen/version.rb#4
|
1181
|
+
Listen::VERSION = T.let(T.unsafe(nil), String)
|