Skip to content

Commit

Permalink
Merge pull request #305 from dscho/upgrade-to-gcm-core
Browse files Browse the repository at this point in the history
Upgrade users to Git Credential Manager Core
  • Loading branch information
dscho committed Sep 30, 2020
2 parents 9fdc41b + 1db0a79 commit 335cf2b
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 9 deletions.
2 changes: 1 addition & 1 deletion git-extra/git-credential-helper-selector.c
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@ static int discover_helpers(void)
selected_helper = 0;

if (!previously_selected_helper)
previously_selected_helper = L"manager";
previously_selected_helper = L"manager-core";

for (p = env; *p; ) {
WCHAR *q = wcschr(p, L';');
Expand Down
19 changes: 12 additions & 7 deletions installer/install.iss
Original file line number Diff line number Diff line change
Expand Up @@ -2038,14 +2038,14 @@ begin
GitCredentialManagerPage:=CreatePage(PrevPageID,'Choose a credential helper','Which credential helper should be configured?',TabOrder,Top,Left);
// 1st choice
RdbGitCredentialManager[GCM_None]:=CreateRadioButton(GitCredentialManagerPage,'None','Do not use a credential helper.',TabOrder,Top,Left);
// Git Credential Manager Core
RdbGitCredentialManager[GCM_Core]:=CreateRadioButton(GitCredentialManagerPage,'Git Credential Manager Core','<RED>(NEW!)</RED> Use the new, <A HREF=https://github.com/microsoft/Git-Credential-Manager-Core>cross-platform version of the Git Credential Manager</A>.'+#13+'See more information about the future of Git Credential Manager <A HREF=https://github.com/microsoft/Git-Credential-Manager-Core/blob/master/docs/faq.md#about-the-project>here</A>.',TabOrder,Top,Left);
// 2nd choice
RdbGitCredentialManager[GCM_Classic]:=CreateRadioButton(GitCredentialManagerPage,'Git Credential Manager','The <A HREF=https://github.com/Microsoft/Git-Credential-Manager-for-Windows>Git Credential Manager for Windows</A> handles credentials e.g. for Azure'+#13+'DevOps and GitHub (requires .NET framework v4.5.1 or later).',TabOrder,Top,Left);
// Git Credential Manager for Windows
RdbGitCredentialManager[GCM_Classic]:=CreateRadioButton(GitCredentialManagerPage,'Git Credential Manager','(DEPRECATED) The <A HREF=https://github.com/Microsoft/Git-Credential-Manager-for-Windows>Git Credential Manager for Windows</A> handles credentials e.g.'+#13+'for Azure DevOps and GitHub (requires .NET framework v4.5.1 or later).',TabOrder,Top,Left);
// 3rd choice
RdbGitCredentialManager[GCM_Core]:=CreateRadioButton(GitCredentialManagerPage,'Git Credential Manager Core','<RED>(NEW!)</RED> Use the new, <A HREF=https://github.com/microsoft/Git-Credential-Manager-Core>cross-platform version of the Git Credential Manager</A>.'+#13+'See more information about the future of Git Credential Manager <A HREF=https://github.com/microsoft/Git-Credential-Manager-Core/blob/master/docs/faq.md#about-the-project>here</A>.',TabOrder,Top,Left);
// No credential helper
RdbGitCredentialManager[GCM_None]:=CreateRadioButton(GitCredentialManagerPage,'None','Do not use a credential helper.',TabOrder,Top,Left);
// Restore the settings chosen during a previous install, if .NET 4.5.1
// or later is available.
Expand All @@ -2055,13 +2055,18 @@ begin
RdbGitCredentialManager[GCM_Core].Checked:=False;
RdbGitCredentialManager[GCM_Core].Enabled:=False;
end else begin
case ReplayChoice('Use Credential Manager','Enabled') of
case ReplayChoice('Use Credential Manager','Core') of
'Disabled': RdbGitCredentialManager[GCM_None].Checked:=True;
'Enabled': RdbGitCredentialManager[GCM_Classic].Checked:=True;
'Core': RdbGitCredentialManager[GCM_Core].Checked:=True;
else
RdbGitCredentialManager[GCM_Classic].Checked:=True;
end;
// Auto-upgrade GCM to GCM Core in version v2.29.0
if RdbGitCredentialManager[GCM_Classic].Checked and (PreviousGitForWindowsVersion<>'') and IsDowngrade(PreviousGitForWindowsVersion,'2.29.0') then begin
RdbGitCredentialManager[GCM_Core].Checked:=True;
AddToSet(CustomPagesWithUnseenOptions,GitCredentialManagerPage);
end;
end;
(*
Expand Down
2 changes: 1 addition & 1 deletion portable/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ die "Could not generate file list"
mkdir -p "$SCRIPT_PATH/root/${etc_gitconfig%/*}" &&
cp /"$etc_gitconfig" "$SCRIPT_PATH/root/$etc_gitconfig" &&
git config -f "$SCRIPT_PATH/root/$etc_gitconfig" \
credential.helper manager ||
credential.helper manager-core ||
die "Could not configure Git-Credential-Manager as default"
test 64 != $BITNESS ||
git config -f "$SCRIPT_PATH/root/$etc_gitconfig" --unset pack.packSizeLimit
Expand Down

0 comments on commit 335cf2b

Please sign in to comment.