GoogleContainerTools / GoogleContainerTools/skaffold
Feature request: --format flag for skaffold diagnose
- Dominant language
- Go
- Stars
- 15.9k
- Forks
- 1.7k
- Avg merge
- 3d 9h
- Merged PRs (30d)
- 10
Description
`skaffold diagnose --yaml-only` is extremely useful for identifying issues with potentially complicated skaffold configurations. It would be fantastic if there were a way to get the errors in json format for easy consumption.
### Input Yaml
```yaml
apiVersion: skaffold/v2beta4
kind: Config
build:
tagPolicy:
sha256: {}
artifacts:
- image: java-hello-world
context: .
docker:
target: mm
deploy:
kubectl:
manifests:
- ./kubernetes-manifests/**.yaml
profiles:
- name: cloudbuild
some-invalid-yaml
build:
googleCloudBuild: {}
- name: dockerfile
build:
artifacts:
- image: java-hello-world
```
### Current output

### Proposed Output
`skaffold diagnose -f skaffold.yaml --yaml-only --format json` might output the following json
```json
{
"errors": [{
"line": 18,
"message": "could not find expected ':'"
}]
}
```
Contributor guide
Assessment
This issue has not been assessed yet.