commit | e8a963245663711ce26a02b572378d41dd98e463 | [log] [tgz] |
---|---|---|
author | Todd Wang <toddw@google.com> | Thu May 14 23:09:55 2015 -0700 |
committer | Todd Wang <toddw@google.com> | Thu May 14 23:09:58 2015 -0700 |
tree | 6106185c20c93194ebb286dda2f8d036a5c8e7d0 | |
parent | b258a532fdb86d080b7cf3d08709283cd1d8bf16 [diff] |
lib: Add support for cmdline.Env.Vars This adds envrionment variable support to cmdline.Env, and also updates some programs to use this support. The main benefit of using cmdline.Env.Vars is that it makes testing easier, since you can just pass in your own map. We represent environment variables as map[string]string, which is a nice simple form for lookups and mutations. Originally I was planning on using *envvar.Vars, but the delta-tracking support is probably unnecessary, and the native Go map syntax is nicer. A subsequent change will update the v23.Init and test.InitForTest mechanisms to support explicit passing of args and envvars, and will take advantage of this support. MultiPart: 1/2 Change-Id: I6044cf72a54254d9abd585908a1b712847b97913
This repository contains general purpose libraries used by the Vanadium project.