803 Commits

Author SHA1 Message Date
Isaev Denis
e560b3f76e
dev: expand website templates during build (#1095) 2020-05-16 14:41:39 +03:00
Isaev Denis
fedbedff4c
docs: add link to website into README.md 2020-05-16 14:17:54 +03:00
Isaev Denis
2d4d503a79
docs: migrate README.md to a website (#1094)
Make a website https://golangci-lint.run
for golangci-lint documentation.
The website is backed by Gatsby static site generator
and deployed into Netlify.
2020-05-16 14:10:03 +03:00
Denis Isaev
a85e1e1faa action: enable v.1.27.0 for github action 2020-05-14 10:49:28 +03:00
Aleksandr Razumov
fb74c2e8e9
dev: prepare release
Some checks failed
CI / golangci-lint (push) Failing after 3m0s
CI / tests-on-windows (push) Has been skipped
CI / tests-on-unix (1.13, macos-latest) (push) Has been skipped
CI / tests-on-unix (1.13, ubuntu-latest) (push) Has been skipped
CI / tests-on-unix (1.14, ubuntu-latest) (push) Has been skipped
CI / check_generated (push) Has been skipped
Release a tag / release (push) Failing after 3m28s
GIT_TAG=v1.27.0 make README.md
v1.27.0
2020-05-13 21:27:04 +03:00
Isaev Denis
6b124f1a0e
fix goerr13 dependencies (#1089) 2020-05-13 21:22:52 +03:00
Aleksandr Razumov
1ccecec4d1
Merge pull request #1084 from tetafro/master
godot: fix issue with `--fix` flag
2020-05-13 11:48:09 +03:00
Denis Krivak
d7648bf202 godot: fix issue with --fix flag 2020-05-13 11:39:08 +03:00
☃ Elliot Shepherd
c88df8f473
Fix nil pointer in codeclimate.go (#1077)
Some issues don't have any source lines
2020-05-11 22:10:39 +03:00
Denis Isaev
206d79fb21 dev: use golangci/golangci-lint-action@v0.2.0 2020-05-09 16:45:26 +03:00
Isaev Denis
55cd9f78a1
dev: generate assets/github-action-config.json (#1073)
It will be used by GitHub action `golangci-lint-action`.

Relates: golangci/golangci-lint-action#11
2020-05-09 15:30:54 +03:00
Collin Kreklow
3c2aa58dc5
Add *println to exception EXC0001 (#1074)
Exception EXC0001 ignores errors on functions like Sprint and Sprintf,
but not Sprintln. Update the exception to include *println as well.
2020-05-09 15:18:17 +03:00
Isaev Denis
cb58d1f82e
speed up CI and golangci-lint (#1070)
Run CI on mac os only with go1.13 and on windows only on go1.14.
Speed up tests. Introduce --allow-parallel-runners.
Block on parallel run lock 5s instead of 60s.
Don't invalidate analysis cache for minor config changes.
2020-05-09 15:15:34 +03:00
Tim Heckman
f0012d3248
Update gosec2 dependency to a tagged version (v2.3.0) (#1079)
When raising #1062 I noted that the gosec dependency had been upgraded to v2,
but needed to be pulled from `master` due to some issues with the v2.2.0 tagged
release. That was tracked in https://github.com/securego/gosec/issues/470.

They've since cut v2.3.0, so let's update to that tagged release before we
release a new version of golangci-lint.
2020-05-09 09:39:05 +03:00
Isaev Denis
2ae94ef731 dev: update issue templates 2020-05-08 00:05:41 +03:00
Denis Isaev
466f9d590b
dev: remove old issue template 2020-05-07 22:38:36 +03:00
Isaev Denis
dde09e5576 dev: update issue templates 2020-05-07 22:37:44 +03:00
Isaev Denis
d2cefe0f1e
Create CODE_OF_CONDUCT.md 2020-05-07 22:34:17 +03:00
ced42
7526c8d347
Add tests, failures and errors attributes on testsuites (#1072) 2020-05-07 17:05:10 +03:00
Denis Isaev
4eaf056399 dev: fix golangci-lint-action version 2020-05-07 15:58:10 +03:00
Denis Isaev
f59ce4c86e dev: use GITHUB_TOKEN instead of GOLANGCI_LINT_TOKEN 2020-05-07 15:48:51 +03:00
Denis Krivak
4e99c75315
Fix godot false positive for cgo export comments (#1067)
godot: fix false positive for exported cgo code
2020-05-05 18:53:06 +03:00
Soichiro Kashima
7f48cc88b8
Fix lint errors on files with //line directive (#1065)
If the target files contains `//line` directive and it indicates
a non-go file, the linter is going to handle it as a go file,
which results in failure.
The cause of this issue is that the linters (`Analyzer`s) are using
`pass.Fset.Position()`. This func returns the adjusted position using
`//line` directive.
The example project reported in #998 has `//line` directive that
indicates other non-go file.
According to the description of "Compiler Directives”
(https://golang.org/cmd/compile/#hdr-Compiler_Directives),
line directives is mainly used for reporting original positions to
the generators or something.
On linters of golangci-lint, `pass.Fset.Position()` is used just to
aggregate file names; we don't have to adjust positions.
This changes `Analyzer`s that use `pass.Fset.Position()` to aggregate
file names to use `pass.Fset.PositionFor()` with `adjusted == false`.

Relates: #998
2020-05-05 18:49:34 +03:00
Isaev Denis
279b6d62d3
speed up a bit (#1064)
Ensure that `unused` is always the last
in execution order. It can speed up packages loading
a bit.

Refactor enabled linters set to remove extra logging.

Relates: #944
2020-05-05 18:45:19 +03:00
Wilkins
ca04ca6b59
Remove reference to golangci.com in README (#997)
This project is shutting down on the 15th April. See the blog below:
https://medium.com/golangci/golangci-com-is-closing-d1fc1bd30e0e
2020-05-05 18:26:02 +03:00
Isaev Denis
38782dd097
dev: use golangci-lint action (#1066) 2020-05-05 17:51:55 +03:00
Aleksandr Razumov
01b726a048
Merge pull request #1069 from golangci/feature/github-actions-mod-cache
dev: add mod cache in gh actions
2020-05-04 15:51:57 +03:00
Aleksandr Razumov
908d91b088
dev: update cache key 2020-05-04 15:42:36 +03:00
Aleksandr Razumov
04f51a5cf4
dev: use setup-go@v2 and mod cache 2020-05-04 15:17:49 +03:00
Aleksandr Razumov
3e55c710d4
dev: remove go 1.12 from workflow 2020-05-04 15:15:54 +03:00
Aleksandr Razumov
bf7eef042b
Merge pull request #1068 from tetafro/unshallow
Fix CI
2020-05-04 14:57:23 +03:00
Denis Krivak
403c2022fc Add unshallow to CI 2020-05-04 14:27:18 +03:00
Isaev Denis
52c9b88c25
reduce mem. usage of unused and update staticcheck (#1063)
The primary improvement is in early clearing of
analyzed package's TypeInfo, facts, etc for
whole program analyzers (`unused`). Clear it when it
becomes unused and GC collects them early. Initially this
clearing was performed for all analyzers except `unused`.

Update staticcheck from v0.0.1-2019.2.3 to v0.0.1-2020.1.4

Also in this commit:
  * speed up loading packages from export data (2.5s -> 2.1s for std)
    by not using mutex for export data since it was allowed in
    x/tools#07722704da13
  * make an order of execution of linters stable
  * update renameio and robustio
  * use robustio in caching

Relates: #987, #994, #995, #1011
2020-05-03 15:20:17 +03:00
iwankgb
77e211ba75
Replacing Travis with Github actions (#1056)
Signed-off-by: Maciej "Iwan" Iwanowski <maciej.iwanowski@critical.today>
2020-05-03 15:17:41 +03:00
Denis Isaev
5c2e8d47f8
Revert "dev: don't run CI on go.12 (#1060)"
This reverts commit e7e2b9e7e5c4987e4d44c5fca7d42d2a1854c789.
2020-05-03 15:16:51 +03:00
Tim Heckman
60fd647987
Update gosec linter to v2; add .test files to .gitignore (#1062)
This change updates the `gosec` linter to its v2 version. It seems like v2
maintained API compatibility for the functionality we use, so we only needed to
update the dependency and imports.

Please note, this does not use a tagged version of `gosec` and instead is the
latest `master` commit due to this issue: https://github.com/securego/gosec/issues/470.
Once this issue is resolved we should update `gosec` to a tagged release.

This also adds a line to the `.gitignore` file, to ignore the `.test` output
files that get generated by `go test`. This could accidentally get left behind,
so no use committing binary files.

Fixes #1052
2020-05-03 14:05:00 +03:00
Isaev Denis
02a4077af9
docs: add issues.include param to .golangci.example.yml (#1061) 2020-05-02 18:12:46 +03:00
Isaev Denis
e7e2b9e7e5
dev: don't run CI on go.12 (#1060)
Also, update node.js version for CI
2020-05-02 18:08:15 +03:00
Isaev Denis
d95671cc1b
docs: add exclude-case-sensitive to .golangci.example.yml (#1058) 2020-05-02 17:57:30 +03:00
Isaev Denis
b5617209b4
dev: update js deps (#1059)
Fix js security issues by:
cd tools && npm install && npm audit fix
2020-05-02 17:56:47 +03:00
Aleksandr Razumov
ca9a53c7f8
Merge pull request #1057 from tetafro/master
Update godot linter
2020-05-02 14:02:59 +03:00
Denis Krivak
ca853d1515 Fix readme 2020-05-02 12:30:41 +03:00
Denis Krivak
7fe9a44fc7 Fix indentetion issue in godot linter 2020-05-02 12:25:59 +03:00
Aleksandr Razumov
1b9f29a304
dev: update changelog 2020-05-01 18:20:37 +03:00
Aleksandr Razumov
6bd10d01fd
dev: prepare v1.26.0
GIT_TAG=v1.26.0 make README.md
v1.26.0
2020-05-01 18:17:09 +03:00
Aleksandr Razumov
49b3993cc9
Merge pull request #1050 from tetafro/master
Update godot linter
2020-04-30 03:22:00 +03:00
Aleksandr Razumov
eeff3902d4
Merge pull request #837 from ashanbrown/asb/nolintlint-internal
Add nolintlint linter as internal linter
2020-04-30 03:20:28 +03:00
Andrew Shannon Brown
ef44e11e17
Merge branch 'master' into asb/nolintlint-internal 2020-04-29 15:27:35 -07:00
Denis Krivak
7f4a711ce6 Update godot linter. 2020-04-29 20:27:23 +03:00
Aleksandr Razumov
224515a9ab
dev: generate readme 2020-04-28 01:09:05 +03:00