In https://github.com/opener-project/language-identifier/blob/master/lib/opener/language_identifier/cli.rb#L72 a call is being made to see if STDIN.tty?
If true - input is set to nil
If false - input is set to STDIN.read
I don't immediately see the reason for this, so the question is: why?
It seems to be broken now, I get a "length" is not defined for nil error.
Did you consider maybe using ARGF.read so that the LanguageIdentifier works both with STDIN and with filenames?
In https://github.com/opener-project/language-identifier/blob/master/lib/opener/language_identifier/cli.rb#L72 a call is being made to see if STDIN.tty?
If true - input is set to nil
If false - input is set to STDIN.read
I don't immediately see the reason for this, so the question is: why?
It seems to be broken now, I get a "length" is not defined for nil error.
Did you consider maybe using ARGF.read so that the LanguageIdentifier works both with STDIN and with filenames?