diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2019-08-24 17:24:45 +0800 |
---|---|---|
committer | Antoine GIRARD <sapk@users.noreply.github.com> | 2019-08-24 11:24:45 +0200 |
commit | f83db078f0603c775cd1b1bb016f996b65a04835 (patch) | |
tree | 9895f852c768d43b384ba36259b44d9506b04093 /contrib | |
parent | 26af3401c36e6316b81b92bf6a776bf2442d251c (diff) | |
download | gitea-f83db078f0603c775cd1b1bb016f996b65a04835.tar.gz gitea-f83db078f0603c775cd1b1bb016f996b65a04835.zip |
Move database settings from models to setting (#7806)
* move database settings from models to setting
* update docs
* fix checkout pr
* fix tests
* fix lint
* remove unsupported tidb options
* correct wrong variable name
* remove tidb totally
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/pr/checkout.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/contrib/pr/checkout.go b/contrib/pr/checkout.go index 7e6351cc63..490d6760c8 100644 --- a/contrib/pr/checkout.go +++ b/contrib/pr/checkout.go @@ -79,16 +79,16 @@ func runPR() { setting.CheckLFSVersion() //models.LoadConfigs() /* - models.DbCfg.Type = "sqlite3" - models.DbCfg.Path = ":memory:" - models.DbCfg.Timeout = 500 + setting.Database.Type = "sqlite3" + setting.Database.Path = ":memory:" + setting.Database.Timeout = 500 */ db := setting.Cfg.Section("database") db.NewKey("DB_TYPE", "sqlite3") db.NewKey("PATH", ":memory:") - setting.LogSQL = true - models.LoadConfigs() + routers.NewServices() + setting.Database.LogSQL = true //x, err = xorm.NewEngine("sqlite3", "file::memory:?cache=shared") var helper testfixtures.Helper = &testfixtures.SQLite{} |