In my local repository see below, I have many versions of same packages downloaded and stored in deb package directory. As Ubuntu always prefer to use the highest version, I don't need the earlier versions downloaded and used. (All are in a same folder).
How can I delete the earlier versions of packages from my local deb's folder ? It is not a feasible solution to delete them manually. (You can't examine the versions in thousands of files)
Maybe a script that checks the version of each package keeping the newer version and deletind older ones can solve this issue.
I am seeking for such script or if some software is founded would be great
I have made my local repository following this how to tutorial.
*** A local repository is an offline storage of packages already downloaded, so that you don't need to download it again)
Note: I'm not referring to clearing the cache of downloaded packages, which can be done with
apt-get clean command.