https://github.com/robert076/namespace-alias
A kubernetes alias for quickly changing namespaces.
https://github.com/robert076/namespace-alias
aliases kubernetes kubernetes-namespace shell
Last synced: about 2 months ago
JSON representation
A kubernetes alias for quickly changing namespaces.
- Host: GitHub
- URL: https://github.com/robert076/namespace-alias
- Owner: Robert076
- Created: 2025-06-22T11:33:14.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-06-22T11:39:05.000Z (about 1 year ago)
- Last Synced: 2025-06-22T12:30:52.933Z (about 1 year ago)
- Topics: aliases, kubernetes, kubernetes-namespace, shell
- Language: Shell
- Homepage:
- Size: 0 Bytes
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 🌎 namespace-alias
A kubernetes alias for switching between namespaces.
### 🚀 Setup:
1. Copy the function inside `alias.sh`
2. Append it to your `~/.zshrc` (use `vim ~/.zshrc`)
3. Apply the content of zshrc (use `source ~/.zshrc`)
### 🌐 Usage
```bash
kubecontext mynamespace
```
> Output: Context "kind-kind" modified. (I am using kind cluster)
If you want an even shorter version, add an alias in your `~/.zshrc` file to call this function: `alias kc='kubecontext'`