Sponsored Content
Top Forums Shell Programming and Scripting Logic to separate the first name in the file Post 302999063 by Aia on Tuesday 13th of June 2017 02:47:00 AM
Old 06-13-2017
Code:
for f in *.rpm; do echo "${f%-[0-9]*}"; done

 

We Also Found This Discussion For You

1. Shell Programming and Scripting

Shell script (sh file) logic to compare contents of one file with another file and output to file

Shell script logic Hi I have 2 input files like with file 1 content as (file1) "BRGTEST-242" a.txt "BRGTEST-240" a.txt "BRGTEST-219" e.txt File 2 contents as fle(2) "BRGTEST-244" a.txt "BRGTEST-244" b.txt "BRGTEST-231" c.txt "BRGTEST-231" d.txt "BRGTEST-221" e.txt I want to get... (22 Replies)
Discussion started by: pottic
22 Replies
All times are GMT -4. The time now is 07:17 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy