Answer the question
In order to leave comments, you need to log in
How to take only the first line of the output?
The construction is as follows:
sysAnswer = system("command")
The output is always:
The first line with the result
true
Further sysAnswer is used in the if condition
How can I do it without true. I 'm redoing someone else's script and zero-zero in Ruby.
I looked on the Internet, there are also constructions a la %[" but they give me a launch error.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question