Delete all but 3 newest files

This is related to my post on backup up files.

I really appreciate all the help too. :slight_smile:

I would like to delete all but the 3 newest files in my backup directory.

/media/andy/MAXTOR_SDB1/Ubuntu_Mate_18.04/

For example

Ubuntu_Documents.zip_09Aug2018_12_00
Ubuntu_Documents.zip_09Aug2018_12_34
Ubuntu_Documents.zip_09Aug2018_12_40
Ubuntu_Documents.zip_09Aug2018_12_42
Ubuntu_Documents.zip_09Aug2018_12_43

Had you taken to heart the advice given in your other thread to use an easy to sort date format ( 2018-08-01T01:02 , or epoch seconds), it would be a simple

ls -1r Ubuntu_Documents.zip_* | tail -n+4

to find the to-be-deleted files...

I put the date first.

2018-08-09-13_Ubuntu_Documents.zip