mirror of
https://gitea.com/gitea/tea.git
synced 2025-12-20 05:12:06 +01:00
use updated token
This commit is contained in:
@@ -110,6 +110,12 @@ var CmdLoginHelper = cli.Command{
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Once token is refreshed, get the latest from the updated config
|
||||||
|
refreshedConfig := config.GetLoginByHost(wants["host"])
|
||||||
|
if refreshedConfig != nil {
|
||||||
|
userConfig = refreshedConfig
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
_, err = fmt.Fprintf(os.Stdout, "protocol=%s\nhost=%s\nusername=%s\npassword=%s\n", host.Scheme, host.Host, userConfig.User, userConfig.Token)
|
_, err = fmt.Fprintf(os.Stdout, "protocol=%s\nhost=%s\nusername=%s\npassword=%s\n", host.Scheme, host.Host, userConfig.User, userConfig.Token)
|
||||||
|
|||||||
Reference in New Issue
Block a user