Add checks for no matching of migration functions count and the length of `migrations` defined in `migrations.go`
For example, for `v284 -> v285`
![image](/attachments/e43c465e-d41f-4755-950d-d3565690ea2a)
remove line 556:
![image](/attachments/a8598239-f123-415a-8090-3bdb781ce6ab)
run `make lint-go-vet`:
![image](/attachments/7a55b7be-6c19-41b5-995f-98d4aa5a7100)
Reviewed-on: https://gitea.com/gitea/gitea-vet/pulls/27
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: yp05327 <576951401@qq.com>
Co-committed-by: yp05327 <576951401@qq.com>
`DenylistImports` will be redundant once [gitea/pull/22412](https://github.com/go-gitea/gitea/pull/22412) has been merged.
Reviewed-on: https://gitea.com/gitea/gitea-vet/pulls/23
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: John Olheiser <john+gitea@jolheiser.com>
Co-authored-by: Jason Song <i@wolfogre.com>
Co-committed-by: Jason Song <i@wolfogre.com>
Reviewed-on: https://gitea.com/gitea/gitea-vet/pulls/22
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: Xinyu Zhou <i@sourcehut.net>
Co-authored-by: Jason Song <wolfogre@noreply.gitea.io>
Co-committed-by: Jason Song <wolfogre@noreply.gitea.io>
Check `SPDX-License-Identifier` in file headers.
Related to https://github.com/go-gitea/gitea/pull/21840
Co-authored-by: Jason Song <i@wolfogre.com>
Reviewed-on: https://gitea.com/gitea/gitea-vet/pulls/21
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: Xinyu Zhou <i@sourcehut.net>
Co-authored-by: Jason Song <wolfogre@noreply.gitea.io>
Co-committed-by: Jason Song <wolfogre@noreply.gitea.io>
- It's dangerous to use this fork over the official one. This one only
will contain changes to the SSH part of x/crypto in order to fix some
bugs. See https://github.com/go-gitea/gitea/pull/18711.
Reviewed-on: https://gitea.com/gitea/gitea-vet/pulls/19
Reviewed-by: 6543 <6543@obermui.de>
Reviewed-by: Norwin <noerw@noreply.gitea.io>
Co-authored-by: Gusted <williamzijl7@hotmail.com>
Co-committed-by: Gusted <williamzijl7@hotmail.com>
- "encoding/json" should be avoided as we got a json module for that which get the correct json library when specified.
- Allow to exemptions to the denylist (e.g. the json module need to import this package).
Reviewed-on: https://gitea.com/gitea/gitea-vet/pulls/18
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: Gusted <williamzijl7@hotmail.com>
Co-committed-by: Gusted <williamzijl7@hotmail.com>
If you call `sess := x.NewSession()` you must call `sess.Close()` or return the session.
This is not quite completely perfect for example if you return the output of x.NewSession() immediately it will falsely claim that you're not closing it. However it shows the beginnings of how to do it.
Signed-off-by: Andrew Thornton <art27@cantab.net>
close#15
Reviewed-on: https://gitea.com/gitea/gitea-vet/pulls/16
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: 6543 <6543@obermui.de>
Co-authored-by: Andrew Thornton <art27@cantab.net>
Co-committed-by: Andrew Thornton <art27@cantab.net>