Revert "Run golangci in server CI (#23240)" (#23299)

This reverts commit 349e5d4573.
This commit is contained in:
Agniva De Sarker 2023-05-05 10:08:35 +05:30 committed by GitHub
parent 8fdbbf3d5b
commit 9f11fc59b5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 22 deletions

View File

@ -87,26 +87,6 @@ jobs:
run: make plugin-checker run: make plugin-checker
- name: Run mattermost-vet - name: Run mattermost-vet
run: make vet BUILD_NUMBER='${GITHUB_HEAD_REF}' MM_NO_ENTERPRISE_LINT=true MM_VET_OPENSPEC_PATH='${PWD}/../../mattermost-api-reference/v4/html/static/mattermost-openapi-v4.yaml' run: make vet BUILD_NUMBER='${GITHUB_HEAD_REF}' MM_NO_ENTERPRISE_LINT=true MM_VET_OPENSPEC_PATH='${PWD}/../../mattermost-api-reference/v4/html/static/mattermost-openapi-v4.yaml'
golangci:
name: golangci-lint
runs-on: ubuntu-22.04
defaults:
run:
working-directory: server
steps:
- name: Checkout mattermost-server
uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3.3.0
- name: Setup Go
uses: actions/setup-go@4d34df0c2316fe8122ab82dc22947d607c0c91f9 # v4.0.0
with:
go-version: ${{ env.go-version }}
cache-dependency-path: server/go.sum
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.52.2
working-directory: server
args: --new-from-rev=HEAD~ --whole-files # This only checks the latest commit for speed.
check-migrations: check-migrations:
name: Check migration files name: Check migration files
runs-on: ubuntu-22.04 runs-on: ubuntu-22.04

View File

@ -291,7 +291,7 @@ else
endif endif
golangci-lint: ## Run golangci-lint on codebase golangci-lint: ## Run golangci-lint on codebase
@# Keep the version in sync with the command in .github/workflows/ci.yml#L107 @# Keep the version in sync with the command in .circleci/config.yml
$(GO) install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.52.2 $(GO) install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.52.2
@echo Running golangci-lint @echo Running golangci-lint
@ -403,7 +403,8 @@ setup-go-work: export BUILD_ENTERPRISE_READY := $(BUILD_ENTERPRISE_READY)
setup-go-work: ## Sets up your go.work file setup-go-work: ## Sets up your go.work file
./scripts/setup_go_work.sh $(IGNORE_GO_WORK_IF_EXISTS) ./scripts/setup_go_work.sh $(IGNORE_GO_WORK_IF_EXISTS)
check-style: plugin-checker vet golangci-lint ## Runs style/lint checks check-style: golangci-lint plugin-checker vet ## Runs style/lint checks
do-cover-file: ## Creates the test coverage report file. do-cover-file: ## Creates the test coverage report file.
@echo "mode: count" > cover.out @echo "mode: count" > cover.out