Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove .PHONY declarations and instead add remake task descriptions #56

Open
falko opened this issue Jul 5, 2023 · 1 comment
Open

Comments

@falko
Copy link
Collaborator

falko commented Jul 5, 2023

This proposal might be controversial and against best practices of make, but the .PHONY declarations are mostly redundant, which makes our Makefiles harder to read and has more than once lead to inconsistencies like this:
https://github.com/camunda-community-hub/camunda-8-helm-profiles/blob/main/google/include/kubernetes-gke.mk#L31-L32

Let's remove them and instead introduce documentation in form of remake task descriptions, e.g.:

#: Install Camunda on Kubernetes
all: camunda await-zeebe rebalance-leaders benchmark

#: Create Kubernetes cluster and install Prometheus & Grafana
kube: kube-gke metrics url-grafana

They can then be extracted using remake --tasks, e.g.:

$ remake --tasks
all                  Install Camunda on Kubernetes
clean                Uninstall Camunda from Kubernetes
clean-kube           Delete entire Kubernetes cluster including metrics data
kube                 Create Kubernetes cluster and install Prometheus & Grafana
url-grafana          Get URL for Grafana
urls                 Get URLs for Kubernetes cluster

And since not everyone has remake installed we can add these to the README.md that accompanies each Helm profile. This would also help people that don't get shell completion for make.

I am already working on a PR for this.

@falko
Copy link
Collaborator Author

falko commented Jul 21, 2023

Apparently .PHONY is useful for something (other than stating the obvious):
https://github.com/jeffsp/makefile_help

Maybe this could be combined with remake task descriptions...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant