Skip to content
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

restore pre-1.11 behavior of kubectl get --template=... #65377

Conversation

juanvallejo
Copy link
Contributor

@juanvallejo juanvallejo commented Jun 22, 2018

Release note:

NONE

Restores old behavior to the --template flag in get.go.
In old releases, providing a --template flag value and no --output value implicitly assigned a default value ("go-template") to --output, printing using the provided template argument.

Example:

# this should print using GoTemplate printer, but currently does not
$ kubectl get pod foo --template="{{ .metadata.name }}"

cc @deads2k @soltysh

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Jun 22, 2018
@juanvallejo
Copy link
Contributor Author

/hold
Will add tests

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 22, 2018
@juanvallejo juanvallejo force-pushed the jvallejo/restore-old-get-template-behavior branch from 8e0cfd0 to 3cb28b0 Compare June 22, 2018 16:34
@juanvallejo
Copy link
Contributor Author

/hold cancel

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 22, 2018
@juanvallejo juanvallejo force-pushed the jvallejo/restore-old-get-template-behavior branch from 3cb28b0 to c94ecfc Compare June 22, 2018 16:36
@liggitt liggitt added this to the v1.11 milestone Jun 22, 2018
@liggitt
Copy link
Member

liggitt commented Jun 22, 2018

adding to the milestone for kubectl printing regression introduced in 1.11

@juanvallejo can you look at failing build:

pkg/kubectl/cmd/get/get_flags.go:38:22: undefined: KubeTemplatePrintFlags

@kubernetes/sig-cli-bugs

@k8s-ci-robot k8s-ci-robot added sig/cli Categorizes an issue or PR as relevant to SIG CLI. kind/bug Categorizes issue or PR as related to a bug. labels Jun 22, 2018
@liggitt
Copy link
Member

liggitt commented Jun 22, 2018

/kind bug
/priority critical-urgent

@k8s-ci-robot k8s-ci-robot added the priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now. label Jun 22, 2018
@liggitt liggitt changed the title special-case template printing in get.go restore pre-1.11 behavior of kubectl get --template=... Jun 22, 2018
@juanvallejo juanvallejo force-pushed the jvallejo/restore-old-get-template-behavior branch 2 times, most recently from c5fbe4d to ed34c00 Compare June 22, 2018 18:46
@liggitt liggitt requested review from deads2k and removed request for smarterclayton June 22, 2018 18:48
@juanvallejo juanvallejo force-pushed the jvallejo/restore-old-get-template-behavior branch from ed34c00 to 508145e Compare June 22, 2018 18:58
@k8s-ci-robot k8s-ci-robot removed the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Jun 22, 2018
@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Jun 22, 2018
Copy link
Contributor

@soltysh soltysh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jun 22, 2018
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: juanvallejo, soltysh

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 22, 2018
@k8s-github-robot
Copy link

[MILESTONENOTIFIER] Milestone Pull Request: Up-to-date for process

@juanvallejo @soltysh

Pull Request Labels
  • sig/cli: Pull Request will be escalated to these SIGs if needed.
  • priority/critical-urgent: Never automatically move pull request out of a release milestone; continually escalate to contributor and SIG through all available channels.
  • kind/bug: Fixes a bug discovered during the current release.
Help

@liggitt
Copy link
Member

liggitt commented Jun 22, 2018

@juanvallejo once CI is green, can you open the pick against the 1.11 branch?

@k8s-github-robot
Copy link

Automatic merge from submit-queue (batch tested with PRs 65377, 63837, 65370, 65294, 65376). If you want to cherry-pick this change to another branch, please follow the instructions here.

@k8s-github-robot k8s-github-robot merged commit c304618 into kubernetes:master Jun 22, 2018
k8s-github-robot pushed a commit that referenced this pull request Jun 25, 2018
…65377-upstream-release-1.11

Automatic merge from submit-queue.

Automated cherry pick of #65377: special-case template printing in get.go

Cherry pick of #65377 on release-1.11.

#65377: special-case template printing in get.go
@juanvallejo juanvallejo deleted the jvallejo/restore-old-get-template-behavior branch June 25, 2018 14:19
@soltysh soltysh mentioned this pull request Jun 26, 2018
17 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/bug Categorizes issue or PR as related to a bug. lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now. release-note-none Denotes a PR that doesn't merit a release note. sig/cli Categorizes an issue or PR as relevant to SIG CLI. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants