[MacPorts] #18952: Stray .TMP files on distfiles mirrors
#18952: Stray .TMP files on distfiles mirrors -------------------------------------+-------------------------------------- Reporter: ryandesign@… | Owner: wsiegrist@… Type: defect | Status: new Priority: Low | Milestone: Component: server/hosting | Version: Keywords: | Port: -------------------------------------+-------------------------------------- It seems that sometimes the distfiles mirror gets interrupted while downloading a file, and then a [http://www.google.com/search?q=site%3Adistfiles.macports.org+"gz.TMP"+OR+"bz2.TMP"+OR+"zip.TMP" .TMP file gets left behind]. This is a bit untidy and it would be nice if the .TMP files could be cleaned up automatically so that they don't appear when browsing the distfiles servers' directory listings. Perhaps a cron task could be installed to periodically clean it up. For example, it could run this command: {{{ find /path/to/distfiles -type f -name '*.TMP' \! -newermt '1 hour ago' -delete }}} This would find and delete files in /path/to/distfiles whose names end with ".TMP" and that were last modified more than an hour ago. If you just want to see what files would be deleted without deleting them, remove "`-delete`" from the command: {{{ find /path/to/distfiles -type f -name '*.TMP' \! -newermt '1 hour ago' }}} The "1 hour" figure is picked a bit at random, but you want some nonzero value in there; you wouldn't want to clean up .TMP files that are currently being downloaded. -- Ticket URL: <http://trac.macports.org/ticket/18952> MacPorts <http://www.macports.org/> Ports system for Mac OS
#18952: Stray .TMP files on distfiles mirrors -------------------------------------+-------------------------------------- Reporter: ryandesign@… | Owner: wsiegrist@… Type: defect | Status: new Priority: Low | Milestone: Component: server/hosting | Version: Keywords: | Port: -------------------------------------+-------------------------------------- Comment(by ryandesign@…): Could this script be implemented? It would be nice to clean up the distfiles directories, and it should be just as simple as the one-liner already provided in the ticket description. -- Ticket URL: <https://trac.macports.org/ticket/18952#comment:1> MacPorts <http://www.macports.org/> Ports system for Mac OS
participants (1)
-
MacPorts