Skip to content

Commit 84d7496

Browse files
authored
Remove fix Make targets (go-gitea#35868)
Since `modernize` is now included in `golangci-lint` since go-gitea@850012b, it makes not sense to have this as a separate make target anymore.
1 parent 525265c commit 84d7496

File tree

1 file changed

+1
-16
lines changed

1 file changed

+1
-16
lines changed

Makefile

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ GO_LICENSES_PACKAGE ?= github.com/google/go-licenses@v1
4141
GOVULNCHECK_PACKAGE ?= golang.org/x/vuln/cmd/govulncheck@v1
4242
ACTIONLINT_PACKAGE ?= github.com/rhysd/actionlint/cmd/actionlint@v1
4343
GOPLS_PACKAGE ?= golang.org/x/tools/[email protected]
44-
GOPLS_MODERNIZE_PACKAGE ?= golang.org/x/tools/gopls/internal/analysis/modernize/cmd/[email protected]
4544

4645
DOCKER_IMAGE ?= gitea/gitea
4746
DOCKER_TAG ?= latest
@@ -276,19 +275,6 @@ fmt-check: fmt
276275
exit 1; \
277276
fi
278277

279-
.PHONY: fix
280-
fix: ## apply automated fixes to Go code
281-
$(GO) run $(GOPLS_MODERNIZE_PACKAGE) -fix ./...
282-
283-
.PHONY: fix-check
284-
fix-check: fix
285-
@diff=$$(git diff --color=always $(GO_SOURCES)); \
286-
if [ -n "$$diff" ]; then \
287-
echo "Please run 'make fix' and commit the result:"; \
288-
printf "%s" "$${diff}"; \
289-
exit 1; \
290-
fi
291-
292278
.PHONY: $(TAGS_EVIDENCE)
293279
$(TAGS_EVIDENCE):
294280
@mkdir -p $(MAKE_EVIDENCE_DIR)
@@ -328,7 +314,7 @@ checks: checks-frontend checks-backend ## run various consistency checks
328314
checks-frontend: lockfile-check svg-check ## check frontend files
329315

330316
.PHONY: checks-backend
331-
checks-backend: tidy-check swagger-check fmt-check fix-check swagger-validate security-check ## check backend files
317+
checks-backend: tidy-check swagger-check fmt-check swagger-validate security-check ## check backend files
332318

333319
.PHONY: lint
334320
lint: lint-frontend lint-backend lint-spell ## lint everything
@@ -852,7 +838,6 @@ deps-tools: ## install tool dependencies
852838
$(GO) install $(GOVULNCHECK_PACKAGE) & \
853839
$(GO) install $(ACTIONLINT_PACKAGE) & \
854840
$(GO) install $(GOPLS_PACKAGE) & \
855-
$(GO) install $(GOPLS_MODERNIZE_PACKAGE) & \
856841
wait
857842

858843
node_modules: pnpm-lock.yaml

0 commit comments

Comments
 (0)