mirror of
https://github.com/halejohn/Cloudreve.git
synced 2026-01-26 17:41:57 +08:00
Feat: Decide whether to do database migration based on version.lock
This commit is contained in:
11
pkg/conf/version.go
Normal file
11
pkg/conf/version.go
Normal file
@@ -0,0 +1,11 @@
|
||||
package conf
|
||||
|
||||
import "io/ioutil"
|
||||
|
||||
const BackendVersion = string("3.0.0-b")
|
||||
|
||||
// WriteVersionLock 将当前版本信息写入 version.lock
|
||||
func WriteVersionLock() error {
|
||||
err := ioutil.WriteFile("version.lock", []byte(BackendVersion), 0644)
|
||||
return err
|
||||
}
|
||||
Reference in New Issue
Block a user