shell - Unix script how to extract string from a file -


how extract value after 4th slash (/) /ftp-test/testautoupdate/test/1/x64 ?

the extracted result example should 1

awk -f'/' '{print $5}' file  kent$  echo "/ftp-test/testautoupdate/test/1/x64"|awk -f'/' '{print $5}' 1    

Comments

Popular posts from this blog

python 3 IndexError: list index out of range -

android - How to save instance state of selected radiobutton on menu -

IF statement in MySQL trigger -