Show message when No input data provided

Thank you csvkit developers
This commit is contained in:
kojix2 2020-10-12 17:10:25 +09:00
parent c4f21df588
commit c40c59a21d

View File

@ -35,8 +35,14 @@ module Uplot
exit
end
watchman = Thread.new do
sleep(1)
warn 'No input file or piped data provided. Waiting for standard input:'
end
# Sometimes the input file does not end with a newline code.
while (input = Kernel.gets(nil))
watchman.kill
input.freeze
@raw_inputs << input
@data = Preprocessing.input(input, delimiter, headers, transpose)