-
Notifications
You must be signed in to change notification settings - Fork 159
Switch to using the packaged yq
#4087
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Oh, |
This is a blocker for #4087. Basically because we are referencing the tmt repo itself in the tests, some of the tests are running steps from the `main` branch in this case https://github.com/teemtee/tmt/blob/b19b58c55eabfe5bd30fe26a33b7452c9d64fb1e/plans/main.fmf#L13-L22 even if I delete those in #4087 because it is taking the `main` ref instead of the current ref. For now a quick workaround is to first merge this in `main` to avoid installing `yq` if already present and then delete it later in #4087. Signed-off-by: Cristian Le <git@lecris.dev>
e869f4e
to
e77c95e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know very little about yq
but based on the flag descriptions you gave the replacements and removals looks correct, just one verification question.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Signed-off-by: Cristian Le <git@lecris.dev>
Signed-off-by: Cristian Le <git@lecris.dev>
This is likely a no-op unlike the `jq -r` Signed-off-by: Cristian Le <git@lecris.dev>
It should not be necessary Signed-off-by: Cristian Le <git@lecris.dev>
yq does not have an equivalent, but instead we can just pipe it to `jq` Signed-off-by: Cristian Le <git@lecris.dev>
Signed-off-by: Cristian Le <git@lecris.dev>
Signed-off-by: Cristian Le <git@lecris.dev>
Signed-off-by: Cristian Le <git@lecris.dev>
Signed-off-by: Cristian Le <git@lecris.dev>
Signed-off-by: Cristian Le <git@lecris.dev>
Signed-off-by: Cristian Le <git@lecris.dev>
Signed-off-by: Cristian Le <git@lecris.dev>
Co-authored-by: graphite-app[bot] <96075541+graphite-app[bot]@users.noreply.github.com>
There is already the packaged go-based
yq
available. It does have some cli differences hence why there was quite a bit of debate on how to getpython-yq
in as well, but realistically it should not make a difference for us since the corejq
compatibility is the same.Pull Request Checklist
yq
flags-y
is equivalent with-o yaml
, however this is likely unnecessary (anymore?)-r
seems to be a no-op now-e
make sure the last output is notfalse
ornull
: equivalent, just keep-c
compact output: no equivalent, just pipe it tojq -c
-S
sort keys: change to"sort_keys(.)"