Skip to content

Empty proxy for scoped section not respected when proxy is set for unscoped #442

@AThomsen

Description

@AThomsen

In gitconfig a default proxy is set and an exemption is made for a local server:

[http]
	proxy = http://:@<enterprise-proxy>
[http "https://<git-server-on-lan>"]
	proxy = 

This works in git but not in GCMC.

The error is in:
https://github.com/microsoft/Git-Credential-Manager-Core/blob/540a39816534e6481eaea35fe706eaa7eeb45fd8/src/shared/Microsoft.Git.CredentialManager/Settings.cs#L431-L445

GetSettingValues returns ["", "http://:@<enterprise-proxy>"].

The first value is empty, so Uri.TryCreate returns false, and thus the next value is used.

A workaround is to set NO_PROXY.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions