Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 166926 - app-portage/gentoolkit: eclean: feature request for removing all files except fetch restricted
Summary: app-portage/gentoolkit: eclean: feature request for removing all files except...
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Tools (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Portage Tools Team
Keywords: NeedPatch
Depends on:
Reported: 2007-02-14 23:41 UTC by Alexander Huemer
Modified: 2016-06-24 03:54 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Huemer 2007-02-14 23:41:02 UTC
i would like to clean up distfiles completely and leave only files with
fetch-restrictons in there.
"eclean -d distfiles -f" leaves over 100 files in distfiles.
i cannot do that manually by "rm", because fetch-restricted files cannot be excepted that way.
such a option should be very easy to implement, unfortunately i have not enough
python experience to do that on my own.

Reproducible: Always
Comment 1 Gilles Dartiguelongue gentoo-dev 2013-02-15 13:25:24 UTC
> i would like to clean up distfiles completely and leave only files with
> fetch-restrictons in there.

It looks like this got implemented:

$ eclean --help
 -f, --fetch-restricted   - protect fetch-restricted files (when --destructive)

Is that what you were asking for ?
Comment 2 Alexander Huemer 2013-02-15 14:11:33 UTC

that sounds like the idea I had back then, yes.
My eclean does not have a --fetch-restricted though.
It is from gentoolkit, according to the gitweb of gentoolkit there were no commits after that tag.
Where do you get your gentoolkit from?
Comment 3 Gilles Dartiguelongue gentoo-dev 2013-02-15 14:40:55 UTC
I have as well from gentoo-x86, nothing fency :).
Plus I remember using this option months ago (if not years) so it's been there for a while afaik.
Comment 4 Brian Dolbec gentoo-dev 2013-02-15 15:38:45 UTC
Fetch-restricted has been implemented since long before I did the re-write for -0.3.0.

-d, --destructive        - only keep the minimum for a reinstallation

--destructive does not clean out all files like the original request.  It keeps any installed pkgs distfiles.  But only the installed version.  It does not keep a backup version's files.

-f, --fetch-restricted   - protect fetch-restricted files (when --destructive)

Your original post here was using -f, --fetch-restricted in the command example.  So, you had that option all along.  Just re-read the first post.

I believe the original intent was to clean even the installed pkgs distfiles.  So everything except fetch-restricted files.

I am somewhat reluctant to add this feature.  I can envision lots of users mis-understanding and wiping out all their distfiles and complaining loudly. Especially those where bandwidth and data transfer are limited.
Comment 5 Paul Varner (RETIRED) gentoo-dev 2016-06-24 03:54:20 UTC
After talking it over, the tools-portage team will not be doing this enhancement. We do understand the use case of wanting to delete everything except fetch restricted files, however, our resources and time are limited and we don't see very many people wanting this feature. 

If patch is provided or another Gentoo developer wants to write it and put it in the repository, we will take those changes.