forgejo/services/forgejo/sanity.go
Earl Warren f6ba73de4c
[UPGRADE] add sanity checks for [storage*]
Refs: https://forgejo.org/2023-08-release-v1-20-3-0/
(cherry picked from commit a266dd0ce3)
(cherry picked from commit b9eb5eccd8)
(cherry picked from commit 7fc2028ede)
(cherry picked from commit 0c988e6120)
(cherry picked from commit 7ba05e8c2b)
(cherry picked from commit 2ed5068abe)
(cherry picked from commit 353913a26d)
(cherry picked from commit 4e63a01a8b)
(cherry picked from commit 99f612aed3)
(cherry picked from commit b4fe189cae)
(cherry picked from commit bd35e3b7bc)
(cherry picked from commit f59d9f7088)
(cherry picked from commit 0b2a93e044)
(cherry picked from commit 8c5d8bfea0)
(cherry picked from commit 2817ce027c)
(cherry picked from commit 162056cbcf)
(cherry picked from commit 07152a0ba6)
(cherry picked from commit 72e3777915)
(cherry picked from commit 3b1ebd95b9)
(cherry picked from commit 14fc4f3fac)
(cherry picked from commit 9052c86e8c)
(cherry picked from commit 16f1cc21ea)
(cherry picked from commit 0fef12f5d8)
(cherry picked from commit d187381f73)
(cherry picked from commit 9dda715111)
2024-02-05 14:44:33 +01:00

27 lines
580 B
Go

// SPDX-License-Identifier: MIT
package forgejo
import (
"code.gitea.io/gitea/models/db"
"code.gitea.io/gitea/modules/log"
"code.gitea.io/gitea/modules/setting"
)
var (
ForgejoV6DatabaseVersion = int64(261) // must be updated once v6 / Gitea v1.21 is out
ForgejoV5DatabaseVersion = int64(260)
ForgejoV4DatabaseVersion = int64(244)
)
var logFatal = log.Fatal
func fatal(err error) error {
logFatal("%v", err)
return err
}
func PreMigrationSanityChecks(e db.Engine, dbVersion int64, cfg setting.ConfigProvider) error {
return v1TOv5_0_1Included(e, dbVersion, cfg)
}