Skip to content

Commit 06ad918

Browse files
committed
add check command
1 parent 25fc732 commit 06ad918

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

deploy/cloud/operator/Makefile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,19 @@ help: ## Display this help.
4444

4545
##@ Development
4646

47+
.PHONY: check
48+
check: generate manifests generate-api-docs
49+
@echo "> Checking for uncommitted changes"
50+
@if [ -n "$$(git status --porcelain)" ]; then \
51+
echo "ERROR: Git tree is dirty after running validation steps."; \
52+
echo "Please check the diff to identify the step that dirtied the tree."; \
53+
git --no-pager status; \
54+
git --no-pager diff; \
55+
exit 1; \
56+
fi
57+
@echo "> Check complete"
58+
59+
4760
.PHONY: ensure-yq
4861
ensure-yq:
4962
@if ! command -v yq &> /dev/null; then \

0 commit comments

Comments
 (0)