git-lfs/httputil
Taylor Blau 8ca4fcbade config: eradicate uses of SetAllEnv
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".
2016-08-03 17:55:39 -06:00
..
certs_darwin.go vendor: vendor dependencies in vendor/ using Glide 2016-05-23 12:10:35 -06:00
certs_freebsd.go Major refactor to pull things into config, httputil, tools 2016-05-13 17:38:06 +01:00
certs_linux.go Major refactor to pull things into config, httputil, tools 2016-05-13 17:38:06 +01:00
certs_openbsd.go Unbreak building httputil on OpenBSD 2016-07-11 19:32:56 +02:00
certs_test.go config: eradicate uses of SetAllEnv 2016-08-03 17:55:39 -06:00
certs_windows.go Major refactor to pull things into config, httputil, tools 2016-05-13 17:38:06 +01:00
certs.go Merge branch 'master' into commands-config 2016-08-01 12:50:18 -06:00
http.go replace config.Config references in httputil 2016-07-21 18:07:23 -06:00
ntlm_test.go replace config.Config references in httputil 2016-07-21 18:07:23 -06:00
ntlm.go replace config.Config references in httputil 2016-07-21 18:07:23 -06:00
proxy_test.go config: eradicate uses of SetAllEnv 2016-08-03 17:55:39 -06:00
proxy.go prefer git config over HTTP_PROXY 2016-07-21 10:06:18 -06:00
request_error_test.go replace config.Config references in httputil 2016-07-21 18:07:23 -06:00
request_test.go more fixes 2016-07-21 11:07:46 -06:00
request.go replace config.Config references in httputil 2016-07-21 18:07:23 -06:00
response.go replace config.Config references in httputil 2016-07-21 18:07:23 -06:00