Skip to content

Commit

Permalink
[BUILD] Ignore 'docker-clean' Output on Failure
Browse files Browse the repository at this point in the history
When docker images don't exist, or have already been removed, the
'docker-clean' target lists failures for 'docker rmi' because it
requires at least on argument.

This ensures at least one argument is passed ('' if no images).

Change-Id: Ie2a47ca028dbafd65fd643c0272bf64fc7bdd030
Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org>
  • Loading branch information
bramwelt committed Nov 23, 2016
1 parent 44b3c13 commit 6ac24f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ protos: gotools

%-docker-clean:
$(eval TARGET = ${patsubst %-docker-clean,%,${@}})
-docker images -q $(PROJECT_NAME)-$(TARGET) | xargs docker rmi -f
-docker images -q $(PROJECT_NAME)-$(TARGET) | xargs -I '{}' docker rmi -f '{}'
-@rm -rf build/image/$(TARGET) ||:

docker-clean: $(patsubst %,%-docker-clean, $(IMAGES))
Expand Down

0 comments on commit 6ac24f3

Please sign in to comment.