just wondering if anyone could help me. I have a file containing a line:
W32i APP - 8.0.0.xxxxx shp 6SFE25~1.EXE
xxxxx are 5 digit numbers and the numbers are different for everytime. I want to be able to search for xxxxx and put it in a variable, so I can use this varibale. Do I use grep and sed?
a.txt
code
output
xxxxx
You’ll be glad that you spend time to understand the difference in how variable modifiers like
${num#xxx}, ${num##xx}, ${num%x}, ${num%%x}work. Advanced shells also supportsedlike substitutions,${num/0/9}and${num//0/9}.IHTH