1
0
mirror of https://github.com/ko-build/ko.git synced 2025-03-17 20:47:51 +02:00

13 Commits

Author SHA1 Message Date
Stanley Nguyen
1c54dd6b3e Add context to go build (#105) 2019-11-09 09:23:09 -08:00
Adam Harwayne
5a25402af9 Ignore null YAML documents when using a label selector. (#107) 2019-11-07 16:12:23 -06:00
Dave Protasowski
4833bb4a3e Preserve YAML comments & style when resolving/applying (#103)
* Preserve YAML comments & style when resolving/applying

This is accomplished by adopting the yaml.v3 lib. It
exposes a Node struct that's used internally by the
yaml encoder/decoder

ko internally now manipulates YAML documents using this struct

Fixes #101

* add/remove vendored modules

* Apply suggestions from code review

Fix comments

Co-Authored-By: jonjohnsonjr <jonjohnson@google.com>

* update doc link

* Fix use of yaml.Decoder in a test

When the yaml.Decoder returns an io.EOF it implies
there were no YAML documents decoded and that there
are no more!

* Update pkg/resolve/resolve.go

resolve comment suggestion

Co-Authored-By: jonjohnsonjr <jonjohnson@google.com>

* leave ko prefix if we're not operating in strict mode

* move testutils to internal/testing
2019-11-05 12:24:08 -08:00
Jason Hall
fee3c269a8 Review feedback 2019-08-15 16:55:26 -04:00
Jason Hall
9776d347fe Improve strict-mode error message 2019-08-15 15:02:02 -04:00
Jason Hall
3315663a21 Remove strictness checks from build, into resolve
Strictness has nothing to do with building, and is independent of how
images are built (fixed builder, some future exotic builder type, etc.)
2019-08-15 14:22:45 -04:00
Jason Hall
4342ceff74 Implement "strict mode"
When ko is invoked in this mode, import paths must have the `ko://`
prefix. If a human marks an import path with `ko://` and ko can't
resolve the resulting import path, it fails. In "loose mode", such an
import path would be silently ignored and passed on to the resolved
YAML, often resulting in invalid image names (e.g., `image:
github.com/foo/bar`)

In loose mode, `ko://` prefixes are always ignored for
backward-compatibility.
2019-08-15 09:45:59 -04:00
jonjohnsonjr
3a0e70e520
Fix mult-doc yaml re-joining (#63) 2019-07-23 09:04:40 -07:00
Scott Weiss
0c205ab8e4 add selector flag and logic (#46)
* add selector flag and logic

* comments, cleanup

* add readme note for selector flag

* preserve comments, fix nits

* readme nit
2019-06-27 13:55:47 -07:00
Jason Hall
86a2d43f43 Drop name.WeakValidation 2019-03-22 15:02:13 -04:00
Jason Hall
4f686b1e6c moar fix 2019-03-21 19:07:56 -04:00
Jason Hall
ab8152ad0a Update ko to ggcr head, update ggcr vendor 2019-03-21 18:51:39 -04:00
Jason Hall
6354665a42 Initial commit 2019-03-14 14:23:47 -04:00