https://github.com/andriisoldatenko/go.mk
Include for Makefile for my personal Go projects, which includes: installing different inting tools and some useful run commands
https://github.com/andriisoldatenko/go.mk
Last synced: 3 months ago
JSON representation
Include for Makefile for my personal Go projects, which includes: installing different inting tools and some useful run commands
- Host: GitHub
- URL: https://github.com/andriisoldatenko/go.mk
- Owner: andriisoldatenko
- License: mit
- Created: 2024-01-03T14:23:49.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-24T23:26:23.000Z (3 months ago)
- Last Synced: 2025-03-25T00:25:28.651Z (3 months ago)
- Language: Makefile
- Size: 12.7 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# go.mk
Include for Makefile for my personal Go projects, which includes: installing different inting tools and some useful run commands## Usage
1. Download latest `go.mk` file
```bash
curl https://raw.githubusercontent.com/andriisoldatenko/go.mk/main/go.mk > go.mk
```2. Include it to your Makefile:
```makefile
# Example of usage
# add this include to you main Makefile-include go.mk
```3. run `make install/go-linting`
4. :tada:## What it includes?
[go.mk](./go.mk) has 3 basic linters ( feel free to add/remove one of your choice)
1. github.com/golangci/golangci-lint
2. github.com/daixiang0/gci
3. golang.org/x/toolsIt includes special comment `# renovate depName=golang.org/x/tools` which helps us later to
configure [renovate](./renovate.json5) to automatically keep up-to-date linter versions etc.#### useful commands:
1. install all linters locally (don't overwrite existing ones):
```bash
$ make install/go-linting
```2. run linting/formating:
```bash
$ make go/lint
go fmt ./...
gci write --skip-generated .
go vet -copylocks=false ./...
make: ./hack/build/create_go_build_tags.sh: Command not found
golangci-lint run --build-tags "" --timeout 300s
```