Skip to content

Commit 1ca2888

Browse files
committed
chore: add fmt command to Makefile
1 parent a7663f2 commit 1ca2888

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

Makefile

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,15 @@ lint:
129129
@echo "Running linters..."
130130
golangci-lint run
131131

132+
# Format Go code
133+
fmt:
134+
@echo "Formatting Go code..."
135+
@$(GOCMD) fmt ./...
136+
@echo "✅ Go code formatted"
137+
138+
# Alias
139+
format: fmt
140+
132141
# Run all linters (CLI + MCP server)
133142
lint-all: lint lint-mcp
134143

@@ -195,6 +204,7 @@ help:
195204
@echo " man-pages Generate Unix manual pages"
196205
@echo " install Install the CLI and manual pages to ~/.local/"
197206
@echo " test Run CLI tests"
207+
@echo " fmt Format Go code"
198208
@echo " lint Run CLI linters"
199209
@echo " clean Clean CLI build artifacts"
200210
@echo ""
@@ -228,4 +238,4 @@ help:
228238
@echo " make version-set VERSION=1.2.3"
229239
@echo " make publish-mcp # Publish MCP server to npm"
230240

231-
.PHONY: all build build-mcp build-all test test-mcp test-all test-coverage clean clean-mcp clean-all tidy deps mcp-deps deps-all lint lint-mcp lint-all man-pages install install-mcp install-all run publish-mcp help
241+
.PHONY: all build build-mcp build-all test test-mcp test-all test-coverage clean clean-mcp clean-all tidy deps mcp-deps deps-all lint lint-mcp lint-all fmt format man-pages install install-mcp install-all run publish-mcp help

0 commit comments

Comments
 (0)