cli
cli copied to clipboard
Add *experimental* commands support
Changes
Commands can be annotated with experimental to be treated as such.
This will show up in usage/help as well as will output a warning
message in stderr on execution.
Examples:
$ tkn task
Available Commands:
create Create a Task from ClusterTask
delete Delete Tasks in a namespace
describe Describe a Task in a namespace
foo* Foo is bar and baz (experimental)
list Lists Tasks in a namespace
logs Show Task logs
start Start Tasks
$ tkn task foo --help
Foo is bar and baz
Usage:
tkn task foo [flags]
EXPERIMENTAL:
tkn task foo is an experimental feature.
Experimental features provide early access to the project functionality. These
features may change between releases without warning, or can be removed from a
future release.
$ tkn task foo
*Warning*: This is an experimental command, it's usage and behavior can change in the next release(s)
Foo is bar
Signed-off-by: Vincent Demeester [email protected]
/kind feature
Closes #1568
Submitter Checklist
These are the criteria that every PR should meet, please check them off as you review them:
- [ ] Includes tests (if functionality changed/added)
- [ ] Run the code checkers with
make check - [ ] Regenerate the manpages, docs and go formatting with
make generated - [x] Commit messages follow commit message best practices
See the contribution guide for more details.
Release Notes
Add a way to mark commands as `experimental` and warn user of their usage
✅ lgtm
The following is the coverage report on the affected files.
Say /test pull-tekton-cli-go-coverage to re-run this coverage report
| File | Old Coverage | New Coverage | Delta |
|---|---|---|---|
| pkg/cmd/task/task.go | 100.0% | 71.4% | -28.6 |
This is great. We can do the same with adm
This is great. We can do the same with
adm
That's the idea 😝
/retest
SGTM!
since we are tweaking and stretching so much the Cobra templates output, we may as well build our own parser 🙃 (jk)
since we are tweaking and stretching so much the Cobra templates output, we may as well build our own parser upside_down_face (jk)
Well, on this, I think we could re-work it a bit as well (mainly the use of -, etc.. to have something more readable that generates what we want 😛
Well, on this, I think we could re-work it a bit as well (mainly the use of -, etc.. to have something more readable that generates what we want stuck_out_tongue
what do you mean by re-work?
Well, on this, I think we could re-work it a bit as well (mainly the use of -, etc.. to have something more readable that generates what we want stuck_out_tongue
what do you mean by re-work?
I do not remember what I meant by my comment 😅
[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by: To complete the pull request process, please ask for approval from vdemeester after the PR has been reviewed.
The full list of commands accepted by this bot can be found here.
Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment
@vdemeester: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:
| Test name | Commit | Details | Required | Rerun command |
|---|---|---|---|---|
| pull-tekton-cli-unit-tests | ae05914952436bb847f76f7ee7f5eb4ffbed3ab5 | link | true | /test pull-tekton-cli-unit-tests |
| pull-tekton-cli-build-tests | ae05914952436bb847f76f7ee7f5eb4ffbed3ab5 | link | true | /test pull-tekton-cli-build-tests |
Full PR test history. Your PR dashboard.
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.
@vdemeester: PR needs rebase.
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale with a justification.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen with a justification.
/lifecycle stale
Send feedback to tektoncd/plumbing.
/remove-lifecycle stale
/approve
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: piyush-garg
The full list of commands accepted by this bot can be found here.
The pull request process is described here
- ~~OWNERS~~ [piyush-garg]
Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment