Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds a run target to the Makefile to align with the make run command documented in the README files. The implementation creates an alias that delegates to the existing dev target, enabling users to successfully run the project using the command shown in the Quick Start documentation.
Key Changes:
- Added a new
runtarget in the Makefile that acts as an alias for the existingdevtarget
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
tools/make/golang.mk
Outdated
| go run cmd/main.go server --config etc/hertzbeat-collector.yaml | ||
|
|
||
| .PHONY: run | ||
| run: dev ## Golang dev, run main by run. Compatible with dev. |
There was a problem hiding this comment.
The comment for the 'run' target is redundant and unclear. Since 'run' is an alias that delegates to 'dev', the comment should describe it as such rather than repeating the same description as 'dev'. Consider changing the comment to something like "Alias for dev target" or "Run the application (alias for dev)" to clarify the relationship and purpose.
| run: dev ## Golang dev, run main by run. Compatible with dev. | |
| run: dev ## Alias for dev target (run the application). |
tools/make/golang.mk
Outdated
| go run cmd/main.go server --config etc/hertzbeat-collector.yaml | ||
|
|
||
| .PHONY: run | ||
| run: dev ## Golang dev, run main by run. Compatible with dev. |
There was a problem hiding this comment.
其实可以改一下,就叫 dev-run 和 prod run 吧?
dev 和 prod 就是以开发模式和二进制运行的意思
There was a problem hiding this comment.
Ok, I made some changes again.
According to the 'make run' command in the README file, I tried but it didn't work. After checking the Makefile file, I found that the 'dev' command can run, but I did not find the 'run' command. So I added the 'run' command, which allows' make run 'to run the project and is compatible with the README file.
