Skip to content

Commit f8aace8

Browse files
committed
feat: added act for local pr check
1 parent 9f73362 commit f8aace8

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

Makefile

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -59,17 +59,19 @@ integration-test:
5959
check:
6060
@scripts/check.sh ./provider/ ./service/
6161

62-
.PHONY: actions
63-
actions: ## Run all the github action checks that run on a pull_request creation
64-
act -l | grep -v ^Stage | grep pull_request | grep -v image_security_scan | awk '{print $$2}' | while read WF; do act pull_request --no-cache-server --platform ubuntu-latest=ghcr.io/catthehacker/ubuntu:act-latest --job "$${WF}"; done
62+
.PHONY: actions action-help
63+
actions: ## Run all GitHub Action checks that run on a pull request creation
64+
@echo "Running all GitHub Action checks for pull request events..."
65+
@act -l | grep -v ^Stage | grep pull_request | grep -v image_security_scan | awk '{print $$2}' | while read WF; do \
66+
echo "Running workflow: $${WF}"; \
67+
act pull_request --no-cache-server --platform ubuntu-latest=ghcr.io/catthehacker/ubuntu:act-latest --job "$${WF}"; \
68+
done
6569

66-
.PHONY: action-help
6770
action-help: ## Echo instructions to run one specific workflow locally
6871
@echo "GitHub Workflows can be run locally with the following command:"
6972
@echo "act pull_request --no-cache-server --platform ubuntu-latest=ghcr.io/catthehacker/ubuntu:act-latest --job <jobid>"
70-
@echo
73+
@echo ""
7174
@echo "Where '<jobid>' is a Job ID returned by the command:"
7275
@echo "act -l"
73-
@echo
74-
@echo "NOTE: if act if not installed, it can be from https://github.com/nektos/act"
75-
76+
@echo ""
77+
@echo "NOTE: if act is not installed, it can be downloaded from https://github.com/nektos/act"

0 commit comments

Comments
 (0)