gitea/services
silverwind b18c047d62
Upgrade `gopls` to v0.19.0, add `make fix` (#34772)
Upgrade to
[v0.19.0](https://github.com/golang/tools/releases/tag/gopls%2Fv0.19.0)
and fix issues. Runs with new `warning` serverity setting. This likely
does less checks than before. Additionally, add `make fix` which runs
modernize. This is also verified on CI.

For the record, here are the issues discoverd when running with `info`
severity, in case we want to fix these:

```
tests/integration/repo_test.go:95:5-14: could use tagged switch on i
tests/integration/api_packages_generic_test.go:149:4-64: could use tagged switch on setting.Packages.Storage.Type
services/webhook/msteams_test.go:33:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:59:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:85:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:111:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:138:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:161:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:187:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:213:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:239:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:266:4-33: could use tagged switch on fact.Name
services/webhook/msteams_test.go:407:4-33: could use tagged switch on fact.Name
tests/integration/api_packages_conan_test.go:350:6-33: could use tagged switch on pf.Name
models/issues/tracked_time_test.go:98:3-18: could use tagged switch on user.ID
tests/integration/api_token_test.go:505:5-43: could use tagged switch on minRequiredLevel
services/gitdiff/gitdiff.go:220:33-46: method "getLineLegacy" is unused
```

---------

Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
2025-06-18 19:30:40 +00:00
..
actions Keeping consistent between UI and API about combined commit status state and fix some bugs (#34562) 2025-06-09 04:05:33 +00:00
agit Option to delay conflict checking of old pull requests until page view (#27779) 2025-04-24 19:26:57 +00:00
asymkey Improve instance wide ssh commit signing (#34341) 2025-06-11 10:32:55 +00:00
attachment Enable testifylint rules (#34075) 2025-03-31 01:53:48 -04:00
auth Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
automerge Option to delay conflict checking of old pull requests until page view (#27779) 2025-04-24 19:26:57 +00:00
context Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
contexttest Add API endpoint to request contents of multiple files simultaniously (#34139) 2025-04-22 01:20:11 +08:00
convert Fix pull requests API convert panic when head repository is deleted. (#34685) 2025-06-10 20:19:52 -07:00
cron Use default Git timeout when checking repo health (#33593) 2025-02-14 15:13:56 +00:00
doctor Remove unused param `doer` (#34545) 2025-06-18 03:12:16 +00:00
externalaccount Enable addtional linters (#34085) 2025-04-01 10:14:01 +00:00
feed Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
forms Allow renaming/moving binary/LFS files in the UI (#34350) 2025-06-16 17:15:07 -07:00
git Fix GetUsersByEmails (#34643) 2025-06-07 18:30:36 +00:00
gitdiff Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
indexer Update issue indexer after merging a PR (#30715) 2024-05-08 14:45:15 +00:00
issue Fix doctor deleting orphaned issues attachments (#34142) 2025-05-30 05:06:03 +00:00
lfs Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
mailer Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
markup Refactor Git Attribute & performance optimization (#34154) 2025-04-11 21:41:29 +08:00
migrations Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
mirror Only git operations should update `last changed` of a repository (#34388) 2025-05-11 19:18:46 +00:00
notify Add workflow_job webhook (#33694) 2025-03-11 10:40:38 -07:00
oauth2_provider Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
org Remove unused param `doer` (#34545) 2025-06-18 03:12:16 +00:00
packages Upgrade `gopls` to v0.19.0, add `make fix` (#34772) 2025-06-18 19:30:40 +00:00
projects Enable addtional linters (#34085) 2025-04-01 10:14:01 +00:00
pull Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
release Enable testifylint rules (#34075) 2025-03-31 01:53:48 -04:00
repository Remove unused param `doer` (#34545) 2025-06-18 03:12:16 +00:00
secrets Added Description Field for Secrets and Variables (#33526) 2025-03-17 19:24:54 +00:00
task Fix bug when migrating repository (#34182) 2025-04-14 04:48:03 +00:00
uinotification
user Fix last admin check when syncing users (#34649) 2025-06-09 20:57:45 +00:00
versioned_migration Add global lock for migrations to make upgrade more safe with multiple replications (#33706) 2025-03-07 21:08:53 +00:00
webhook Refactor some tests (#34580) 2025-06-03 01:26:19 +00:00
webtheme Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00
wiki Run `gopls modernize` on codebase (#34751) 2025-06-18 01:48:09 +00:00