commit | 3e38992fbee06974da202e8491902dbfb80e2e2d | [log] [tgz] |
---|---|---|
author | Todd Wang <toddw@google.com> | Thu May 14 23:09:38 2015 -0700 |
committer | Todd Wang <toddw@google.com> | Thu May 14 23:09:41 2015 -0700 |
tree | d0b87f5d4c5b68c717f992fb4ab6133ef7612a2f | |
parent | 3bb46f5d7d26b272a26c74700c0191346943f3a6 [diff] |
ref: 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: 2/2 Change-Id: Ic9bb9a71b05fd73dafa630f069236c716ee33fb2
This repository contains a reference implementation of the Vanadium APIs.
Unlike the APIs in https://github.com/vanadium/go.v23, which promises to provide backward compatibility this repository makes no such promises.