I have a folder which have multiple Jar files.
Using find, I need to find first file starting with "myjar"
Now, I want to grep the contents of the Manifest file inside the Jar file found using find command.
I am using following command to check contents of Manifest file.
java -jar $(find . -type f -name "myjar-*" -print | head -n 1) -ai
It gives output on console -
Version: 2 Name: MyName Company: ABC
Now, since on console i can see the contents of the file, how can I search whether "Na" exists for line which contains "Name" ?