all repos — searchix @ 2cabf3a22cbfa573559f55ee78c6a02025e8f409

Search engine for NixOS, nix-darwin, home-manager and NUR users

ci: move code formatting responsibility to golangci-lint

Alan Pearce
commit

2cabf3a22cbfa573559f55ee78c6a02025e8f409

parent

40d106a50be7fa87739e82c87c161db8e6a69b12

4 files changed, 11 insertions(+), 16 deletions(-)

changed files
M .golangci.yaml.golangci.yaml
@@ -73,6 +73,15 @@ - third_party$
- builtin$ - examples$ formatters: + enable: + - gofumpt + - golines + - goimports + settings: + gofmt: + simplify: true + golines: + tab-len: 2 exclusions: generated: lax paths:
M flake.nixflake.nix
@@ -59,8 +59,6 @@ programs = {
nixfmt.enable = true; taplo.enable = true; prettier.enable = true; - gofumpt.enable = true; - golines.enable = true; sqlfluff.enable = true; sqlfluff.dialect = "sqlite"; };
M justfilejustfile
@@ -15,14 +15,10 @@
update-dependencies: update-go-dependencies update-nix-dependencies checkformat: - gofmt -d . - goimports -d . - golines --dry-run . + golangci-lint fmt --diff format: - gofmt -w . - goimports -w . - golines -w . + golangci-lint fmt fix: go fix .
M nix/pre-commit-checks.nixnix/pre-commit-checks.nix
@@ -43,14 +43,6 @@
yamllint = { enable = true; }; - golines = { - enable = true; - name = "golines"; - description = "A golang formatter that fixes long lines"; - types_or = [ "go" ]; - entry = "${pkgs.golines}/bin/golines --write-output"; - pass_filenames = true; - }; go-mod-tidy = { enable = true; name = "go-mod-tidy";