Answer the question
In order to leave comments, you need to log in
Extracting a specific line (by number) bash?
Hello! I am writing a script to set up a network and I need to extract the names of the network interfaces and add them to a variable accordingly. First of all, I greped out their names, and now I have the names of network interfaces for each interface on a new line. I need to add each interface to a variable, I tried awk, but I can't select the second, third line. How to implement so that each new line is extracted?
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