github.com/qjfoidnh/BaiduPCS-Go@v0.0.0-20231011165705-caa18a3765f3/internal/pcscommand/pcscommand.go (about) 1 // Package pcscommand 命令包 2 package pcscommand 3 4 import ( 5 "github.com/qjfoidnh/BaiduPCS-Go/baidupcs" 6 "github.com/qjfoidnh/BaiduPCS-Go/internal/pcsconfig" 7 "github.com/qjfoidnh/BaiduPCS-Go/pcsverbose" 8 ) 9 10 var ( 11 pcsCommandVerbose = pcsverbose.New("PCSCOMMAND") 12 ) 13 14 // GetActiveUser 获取当前登录的百度帐号 15 func GetActiveUser() *pcsconfig.Baidu { 16 return pcsconfig.Config.ActiveUser() 17 } 18 19 // GetBaiduPCS 从配置读取BaiduPCS 20 func GetBaiduPCS() *baidupcs.BaiduPCS { 21 return pcsconfig.Config.ActiveUserBaiduPCS() 22 }