Skip to content
Commit 79456a18 authored by Ryan Roberts's avatar Ryan Roberts
Browse files

clean: Simplify approach to cleaning



Each component has 2 directories which matter; source and build. We
delete the build directory and `git clean --xdff` any repos within the
source directory. Previously, we were trying to be too clever with `git
reset`. But now that `shrinkwrap build` ensures the repos are synced,
there is no need for this in clean.

So let's simplify; get rid of --deep and always do the `git clean`.
Since we are always doing this, there is no need for a component to be
able to specify custom clean commands - they are just adding latency
when cleaning.

There is one corner case, which I'm choosing to ignore. If a component
doesn't have any repos defined, but does have a custom sourcedir, there
is no way to clean that custom source dir. But this is not really a
valid approach. All components should have a repo if they have sources.
And users should only be overriding sourcedir to point to a local git
repo. And everything works in that case.

Signed-off-by: Ryan Roberts's avatarRyan Roberts <ryan.roberts@arm.com>
parent 2595c355
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment