Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
bae2db8b
Commit
bae2db8b
authored
Mar 02, 2018
by
Nikhita Raghunath
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bump(6644d4): spf13/cobra: support bash completion for aliases
parent
ae1fc13a
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
80 additions
and
54 deletions
+80
-54
Godeps.json
Godeps/Godeps.json
+0
-0
Godeps.json
...ing/src/k8s.io/apiextensions-apiserver/Godeps/Godeps.json
+1
-1
Godeps.json
staging/src/k8s.io/kube-aggregator/Godeps/Godeps.json
+1
-1
Godeps.json
staging/src/k8s.io/sample-apiserver/Godeps/Godeps.json
+1
-1
bash_completions.go
vendor/github.com/spf13/cobra/bash_completions.go
+63
-51
bash_completions.md
vendor/github.com/spf13/cobra/bash_completions.md
+14
-0
No files found.
Godeps/Godeps.json
View file @
bae2db8b
This diff is collapsed.
Click to expand it.
staging/src/k8s.io/apiextensions-apiserver/Godeps/Godeps.json
View file @
bae2db8b
...
...
@@ -584,7 +584,7 @@
},
{
"ImportPath"
:
"github.com/spf13/cobra"
,
"Rev"
:
"
93959269ad99e80983c9ba742a7e01203a4c0e4f
"
"Rev"
:
"
6644d46b81fa1831979c4cded0106e774e0ef0ab
"
},
{
"ImportPath"
:
"github.com/spf13/pflag"
,
...
...
staging/src/k8s.io/kube-aggregator/Godeps/Godeps.json
View file @
bae2db8b
...
...
@@ -268,7 +268,7 @@
},
{
"ImportPath"
:
"github.com/spf13/cobra"
,
"Rev"
:
"
93959269ad99e80983c9ba742a7e01203a4c0e4f
"
"Rev"
:
"
6644d46b81fa1831979c4cded0106e774e0ef0ab
"
},
{
"ImportPath"
:
"github.com/spf13/pflag"
,
...
...
staging/src/k8s.io/sample-apiserver/Godeps/Godeps.json
View file @
bae2db8b
...
...
@@ -252,7 +252,7 @@
},
{
"ImportPath"
:
"github.com/spf13/cobra"
,
"Rev"
:
"
93959269ad99e80983c9ba742a7e01203a4c0e4f
"
"Rev"
:
"
6644d46b81fa1831979c4cded0106e774e0ef0ab
"
},
{
"ImportPath"
:
"github.com/spf13/pflag"
,
...
...
vendor/github.com/spf13/cobra/bash_completions.go
View file @
bae2db8b
This diff is collapsed.
Click to expand it.
vendor/github.com/spf13/cobra/bash_completions.md
View file @
bae2db8b
...
...
@@ -204,3 +204,17 @@ __kubectl_get_namespaces()
fi
}
```
# Using bash aliases for commands
You can also configure the
`bash aliases`
for the commands and they will also support completions.
```
bash
alias
aliasname
=
origcommand
complete
-o
default
-F
__start_origcommand aliasname
# and now when you run `aliasname` completion will make
# suggestions as it did for `origcommand`.
$)
aliasname <tab><tab>
completion firstcommand secondcommand
```
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment