8ca4fcbade
The `SetAllEnv` function is one of two functions that allow for mutable behavior within the `*config.Configuration` type. It is desirable for us to remove that function, and all of its uses throughout the LFS codebase. Unfortunately, a lot of `SetAllEnv` uses are coupled to initializing the `config.Configuration` instance with custom `.gitconfig` data, a-la `NewFromValues`. This coupling makes it difficult to write an atomic commit that *only* removes the usage of `SetAllEnv`. As a compromise, the signature of `NewFromValues` changed from: ``` func NewFromValues(gitconfig map[string]strimg) *Configuration ``` to... ``` type Values struct { Git, Env map[string]string } func NewFrom(v Values) *Configuration ``` To support reading fixed data as a part of the `Env` fetcher, a new Fetcher type was introduced: ``` type mapFetcher map[string]string func (m mapFetcher) Get(key string) (val string) { ... } ``` and is used in place of the old `*EnvFetcher` to retrieve data from the "environment". |
||
---|---|---|
.. | ||
certs_darwin.go | ||
certs_freebsd.go | ||
certs_linux.go | ||
certs_openbsd.go | ||
certs_test.go | ||
certs_windows.go | ||
certs.go | ||
http.go | ||
ntlm_test.go | ||
ntlm.go | ||
proxy_test.go | ||
proxy.go | ||
request_error_test.go | ||
request_test.go | ||
request.go | ||
response.go |