mirror of
https://github.com/usememos/memos.git
synced 2025-11-08 08:21:49 +08:00
chore: move dsn output to dev mode
This commit is contained in:
parent
4dfe078f3e
commit
9957f8e290
1 changed files with 5 additions and 2 deletions
|
|
@ -141,17 +141,20 @@ func init() {
|
||||||
}
|
}
|
||||||
|
|
||||||
func printGreetings(profile *profile.Profile) {
|
func printGreetings(profile *profile.Profile) {
|
||||||
|
if profile.IsDev() {
|
||||||
|
println("Development mode is enabled")
|
||||||
|
println("DSN: ", profile.DSN)
|
||||||
|
}
|
||||||
fmt.Printf(`---
|
fmt.Printf(`---
|
||||||
Server profile
|
Server profile
|
||||||
version: %s
|
version: %s
|
||||||
data: %s
|
data: %s
|
||||||
dsn: %s
|
|
||||||
addr: %s
|
addr: %s
|
||||||
port: %d
|
port: %d
|
||||||
mode: %s
|
mode: %s
|
||||||
driver: %s
|
driver: %s
|
||||||
---
|
---
|
||||||
`, profile.Version, profile.Data, profile.DSN, profile.Addr, profile.Port, profile.Mode, profile.Driver)
|
`, profile.Version, profile.Data, profile.Addr, profile.Port, profile.Mode, profile.Driver)
|
||||||
|
|
||||||
print(greetingBanner)
|
print(greetingBanner)
|
||||||
if len(profile.Addr) == 0 {
|
if len(profile.Addr) == 0 {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue