delete-package-versions icon indicating copy to clipboard operation
delete-package-versions copied to clipboard

Is it possible to delete superfluous artifacts from a snapshot version?

Open carlislefox opened this issue 2 years ago • 5 comments

Hi there,

Sorry to raise an issue for this but I can't figure it out using the readme alone. When you publish snapshots using maven you end up with an entire set of artifacts against a package with a different timestamp for every single build, this is resulting in me having a package version of say, 0.0.2-SNAPSHOT but it has a billion artifacts underneath it, a full set from each time the snapshot was built.

Is it possible to retain only the latest set of artifacts against a package version with this action? I only ever need the latest snapshot, I'm going to max my GitHub storage on one snapshot version at this rate :(

Thanks for your time, Fhox

carlislefox avatar Mar 31 '22 18:03 carlislefox

Have you figured out how to do this?

woj-tek avatar Jun 13 '22 12:06 woj-tek

https://github.community/t/github-actions-to-purge-maven-repo-hosted-via-github-packages/165472/2

Looks like this isn't supported because they manage all the timestamped SNAPSHOT versions as a single version from GitHub Packages perspective

rvesse avatar Jul 14 '22 09:07 rvesse

This is kinda terrible and... somewhat against maven principle? I'd say it's a bug on GitHub part...

woj-tek avatar Jul 14 '22 10:07 woj-tek

Any news on that on? Or any way to remove accumulated SNAPSHOTs and to keep only newest one ?

ArturJarosz avatar Nov 25 '23 21:11 ArturJarosz

Two years after and there's not even a workaround for this? From what I understood the only workaround is to completely delete the version, which seems a little bit too much. It cannot apply for public packages and maybe you still want to keep x latest versions, not only the last. https://stackoverflow.com/questions/68521637/how-to-delete-old-snapshot-artifacts-from-github-packages

beradrian avatar Feb 16 '24 17:02 beradrian