Hello and happy new year. I have a question;i have a file named shipsIMO.txt in unix which contains the imo code of ships like:
IMO84855
IMO58484
How can I have as an output only the numbers using a bash script? Am I close?
echo "shipsIMO.txt"|tr -cd [:digit:]>single.txt