diff options
author | 赵智超 <1012112796@qq.com> | 2020-07-08 03:16:34 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-07 15:16:34 -0400 |
commit | 12f9dd8fa9c02be1c38f7994066c986e50dfd2e9 (patch) | |
tree | 3113d3d93797315f5baf5790a02f69c09e98808a /cmd/doctor.go | |
parent | 88ef04dbe9e1d4065df98e71a5914674a3bb40a3 (diff) | |
download | gitea-12f9dd8fa9c02be1c38f7994066c986e50dfd2e9.tar.gz gitea-12f9dd8fa9c02be1c38f7994066c986e50dfd2e9.zip |
Decrease the num_stars when deleting a repo (#11954)
* Decrease the num_stars when deleting a repo
fix #11949
Signed-off-by: a1012112796 <1012112796@qq.com>
* Add migration
* use batch
* Apply suggestions from code review
Co-authored-by: Lauris BH <lauris@nix.lv>
* fix lint
* fix lint
* fix ci
* fix ci2
* add doctor
* duplicate code
* fix migration
* fix some nits
* add start
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'cmd/doctor.go')
-rw-r--r-- | cmd/doctor.go | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/cmd/doctor.go b/cmd/doctor.go index 45a50c8266..48fd3158a4 100644 --- a/cmd/doctor.go +++ b/cmd/doctor.go @@ -120,6 +120,12 @@ var checklist = []check{ isDefault: false, f: runDoctorPRMergeBase, }, + { + title: "Recalculate Stars number for all user", + name: "recalculate_stars_number", + isDefault: false, + f: runDoctorUserStarNum, + }, // more checks please append here } @@ -494,6 +500,10 @@ func runDoctorPRMergeBase(ctx *cli.Context) ([]string, error) { return results, err } +func runDoctorUserStarNum(ctx *cli.Context) ([]string, error) { + return nil, models.DoctorUserStarNum() +} + func runDoctorScriptType(ctx *cli.Context) ([]string, error) { path, err := exec.LookPath(setting.ScriptType) if err != nil { |