mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-06-21 22:04:06 -06:00
ide: github token support
git-svn-id: svn://ultimatepp.org/upp/trunk@15643 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
be7aa36411
commit
14e35e1af0
2 changed files with 10 additions and 4 deletions
|
|
@ -24,11 +24,16 @@ int UrepoConsole::Git(const char *dir, const char *command, bool pwd)
|
|||
String username, password;
|
||||
if(url.StartsWith("https://") && GetCredentials(url, dir, username, password)) {
|
||||
String https = "https://";
|
||||
cmd << ' ' << https << UrlEncode(username) + ":";
|
||||
cmd << ' ' << https;
|
||||
if(username.GetCount())
|
||||
cmd << UrlEncode(username) + ":";
|
||||
int p = cmd.GetCount();
|
||||
DDUMP(password);
|
||||
DDUMP(UrlEncode(password));
|
||||
cmd << UrlEncode(password);
|
||||
HidePassword(p, cmd.GetCount());
|
||||
cmd << "@" << url.Mid(https.GetCount());
|
||||
DDUMP(cmd);
|
||||
}
|
||||
}
|
||||
int code = CheckSystem(cmd);
|
||||
|
|
|
|||
|
|
@ -34,16 +34,17 @@ LAYOUT(GitOptionsLayout, 164, 16)
|
|||
ITEM(Upp::Option, pull, SetLabel(t_("Pull")).LeftPosZ(116, 48).VCenterPosZ(16, 0))
|
||||
END_LAYOUT
|
||||
|
||||
LAYOUT(CredentialLayout, 368, 116)
|
||||
LAYOUT(CredentialLayout, 368, 140)
|
||||
ITEM(Upp::Label, dv___0, SetLabel(t_("Url (or directory)")).LeftPosZ(8, 92).TopPosZ(8, 19))
|
||||
ITEM(WithDropChoice<EditString>, url, LeftPosZ(112, 248).TopPosZ(8, 19))
|
||||
ITEM(Upp::Label, dv___2, SetLabel(t_("Username")).LeftPosZ(8, 92).TopPosZ(32, 19))
|
||||
ITEM(Upp::EditString, username, LeftPosZ(112, 248).TopPosZ(32, 19))
|
||||
ITEM(Upp::Label, dv___4, SetLabel(t_("Password")).LeftPosZ(8, 92).TopPosZ(56, 19))
|
||||
ITEM(Upp::Label, dv___4, SetLabel(t_("Password / token")).LeftPosZ(8, 92).TopPosZ(56, 19))
|
||||
ITEM(Upp::EditString, password, LeftPosZ(112, 248).TopPosZ(56, 19))
|
||||
ITEM(Upp::Option, show_password, SetLabel(t_("Show password")).LeftPosZ(8, 108).TopPosZ(84, 20))
|
||||
ITEM(Upp::Option, show_password, SetLabel(t_("Show password")).LeftPosZ(8, 108).TopPosZ(108, 20))
|
||||
ITEM(Upp::Button, cancel, SetLabel(t_("Cancel")).LeftPosZ(228, 64).BottomPosZ(8, 24))
|
||||
ITEM(Upp::Button, ok, SetLabel(t_("OK")).LeftPosZ(296, 64).BottomPosZ(8, 24))
|
||||
ITEM(Upp::Label, dv___9, SetLabel(t_("Note: To use github OAuth token, leave the username empty")).SetFont(StdFont().Italic()).LeftPosZ(8, 360).TopPosZ(84, 19))
|
||||
END_LAYOUT
|
||||
|
||||
LAYOUT(PasskeyLayout, 368, 92)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue