mirror of
https://github.com/mindoc-org/mindoc.git
synced 2025-09-20 02:37:59 +08:00
修改更新程序
This commit is contained in:
@@ -23,6 +23,14 @@ func Update() {
|
|||||||
}else if adapter == "sqlite3" {
|
}else if adapter == "sqlite3" {
|
||||||
sqliteUpdate()
|
sqliteUpdate()
|
||||||
}
|
}
|
||||||
|
o := orm.NewOrm()
|
||||||
|
|
||||||
|
b,err := ioutil.ReadFile("./data/data.sql")
|
||||||
|
|
||||||
|
if err != nil {
|
||||||
|
panic(err.Error())
|
||||||
|
os.Exit(1)
|
||||||
|
}
|
||||||
fmt.Println("update successed.")
|
fmt.Println("update successed.")
|
||||||
|
|
||||||
os.Exit(0)
|
os.Exit(0)
|
||||||
@@ -98,6 +106,4 @@ func sqliteUpdate() {
|
|||||||
os.Exit(1)
|
os.Exit(1)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
os.Exit(1)
|
|
||||||
}
|
}
|
Reference in New Issue
Block a user