commit | 50f483922eda9e3bf3ae07db9b2d27bdf9d9e645 | [log] [tgz] |
---|---|---|
author | Vadim Shtayura <vadimsh@chromium.org> | Fri Jan 25 00:10:48 2019 |
committer | Commit Bot <commit-bot@chromium.org> | Fri Jan 25 00:10:48 2019 |
tree | 5f1b77b655d8e38bc981d29ec96e479f6ff951e9 | |
parent | 9a65d144a5e6c1daa63fb0ae32277bf998e8e97f [diff] |
[lucicfg] Implement 'generate' and half of 'validate' subcommands. 'validate' is kept backward compatible with what we had already (validating arbitrary, not necessary generated, config sets). Brief explanation of supported modes: $ lucicfg generate main.star Generates *.cfg files and puts them in the output directory set via meta.config(config_dir=...) or via -config-dir flag. $ lucicfg generate main.star -validate Same as above, but also sends generated configs to LUCI Config for validation. $ lucicfg validate <DIR> -config-set ... Read-only operation, can be used from presubmits. Takes files from <DIR> and sends them to LUCI Config for validation. $ lucicfg validate main.star (not implemented yet) Read-only operation, can be used from presubmits. Generates *.cfg into memory, compares them to existing files on disk, failing if there's a diff. Otherwise sends generated configs to LUCI Config for validation. R=tandrii@chromium.org, nodir@chromium.org BUG=833946 Change-Id: I886f99c18ac22f0ebf06558b26837853ec092134 Reviewed-on: https://chromium-review.googlesource.com/c/1435656 Commit-Queue: Vadim Shtayura <vadimsh@chromium.org> Reviewed-by: Nodir Turakulov <nodir@chromium.org>
LUCI Go code is meant to be worked on from an Chromium infra.git checkout, which enforces packages versions and Go toolchain version. First get fetch via depot_tools.git then run:
fetch infra cd infra/go eval `./env.py` cd src/go.chromium.org/luci
Contributing uses the same flow as Chromium contributions.