diff --git a/00-empty/.golangci.yaml b/00-empty/.golangci.yaml index 777f1a9..7f25495 100644 --- a/00-empty/.golangci.yaml +++ b/00-empty/.golangci.yaml @@ -1,4 +1,8 @@ --- +# golangci-lint configuration file made by @ccoVeille +# Source: https://github.com/ccoVeille/golangci-lint-config-examples/tree/main/00-empty +# License: MIT +# # empty file to force using the default settings # otherwise golangci-lint looks for .golangci.yaml files # in parent folders diff --git a/00-empty/README.md b/00-empty/README.md index 918f096..c279a3f 100644 --- a/00-empty/README.md +++ b/00-empty/README.md @@ -5,3 +5,10 @@ One way to use the default settings is to use `--no-config` parameter. Another is to create an empty YAML file See [.golangci.yaml](.golangci.yaml) + +## License + +License: MIT + +golangci-lint configuration file made by @ccoVeille +Source: https://github.com/ccoVeille/golangci-lint-config-examples/tree/main/00-empty diff --git a/01-defaults/.golangci.yaml b/01-defaults/.golangci.yaml index 4d809ad..534eab8 100644 --- a/01-defaults/.golangci.yaml +++ b/01-defaults/.golangci.yaml @@ -1,4 +1,8 @@ --- +# golangci-lint configuration file made by @ccoVeille +# Source: https://github.com/ccoVeille/golangci-lint-config-examples/tree/main/01-defaults +# License: MIT +# linters: # some linters are enabled by default # https://golangci-lint.run/usage/linters/ diff --git a/01-defaults/README.md b/01-defaults/README.md index 4c61450..3931986 100644 --- a/01-defaults/README.md +++ b/01-defaults/README.md @@ -4,6 +4,13 @@ These are the currently available linter that are enabled in the current last `g See [.golangci.yaml](.golangci.yaml) +## License + +License: MIT + +golangci-lint configuration file made by @ccoVeille +Source: https://github.com/ccoVeille/golangci-lint-config-examples/tree/main/01-defaults + ## Enabled linters ### errcheck diff --git a/02-basics/.golangci.yaml b/02-basic/.golangci.yaml similarity index 81% rename from 02-basics/.golangci.yaml rename to 02-basic/.golangci.yaml index 0678ce1..18a6f1e 100644 --- a/02-basics/.golangci.yaml +++ b/02-basic/.golangci.yaml @@ -1,4 +1,8 @@ --- +# golangci-lint configuration file made by @ccoVeille +# Source: https://github.com/ccoVeille/golangci-lint-config-examples/tree/main/02-basic +# License: MIT +# linters: # some linters are enabled by default # https://golangci-lint.run/usage/linters/ diff --git a/02-basics/README.md b/02-basic/README.md similarity index 93% rename from 02-basics/README.md rename to 02-basic/README.md index 1588cdb..0cdf0f7 100644 --- a/02-basics/README.md +++ b/02-basic/README.md @@ -1,10 +1,17 @@ -# Safe Settings +# Basic Settings See [.golangci.yaml](.golangci.yaml) It's [01-defaults](../01-defaults) plus : - [revive](#revive) +## License + +License: MIT + +golangci-lint configuration file made by @ccoVeille +Source: https://github.com/ccoVeille/golangci-lint-config-examples/tree/main/02-basics + ## Enabled linters ### errcheck diff --git a/03-safe/.golangci.yaml b/03-safe/.golangci.yaml index 3eeaf71..4c75197 100644 --- a/03-safe/.golangci.yaml +++ b/03-safe/.golangci.yaml @@ -1,4 +1,8 @@ --- +# golangci-lint configuration file made by @ccoVeille +# Source: https://github.com/ccoVeille/golangci-lint-config-examples/tree/main/03-safe +# License: MIT +# linters: # some linters are enabled by default # https://golangci-lint.run/usage/linters/ diff --git a/03-safe/README.md b/03-safe/README.md index f4c0085..c395cee 100644 --- a/03-safe/README.md +++ b/03-safe/README.md @@ -1,8 +1,8 @@ -# Safer Settings +# Safe Settings See [.golangci.yaml](.golangci.yaml) -It's [02-basics](../02-basics) plus : +It's [02-basic](../02-basic) plus : - [gci](#gci) - [thelper](#thelper) - [mirror](#mirror) @@ -10,6 +10,13 @@ It's [02-basics](../02-basics) plus : - [dupwords](#dupwords) - [misspell](#misspell) +## License + +License: MIT + +golangci-lint configuration file made by @ccoVeille +Source: https://github.com/ccoVeille/golangci-lint-config-examples/tree/main/03-safe + ## Enabled linters ### errcheck diff --git a/README.md b/README.md index 79a3d37..04d633e 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,27 @@ # Configuration examples for golangci-lint These are `.golangci.yaml` examples to use in your projects + +## Variants + +- [00-empty](./00-empty) +- [01-defaults](./01-defaults) +- [02-basic](./02-basic) +- [03-safe](./03-safe) + +The bigger the number is the more rules it has. + +Each variant adds rules to the earlier one. + +## License + +License: MIT + +golangci-lint configuration file made by @ccoVeille +Source: https://github.com/ccoVeille/golangci-lint-config-examples + +## Changelog + +- 2024-06-28 - golangci-lint:1.59.1 + + initial version