fish: add tmux-refresh-env function
This commit is contained in:
parent
e6002533da
commit
7efb24059c
1 changed files with 12 additions and 0 deletions
|
@ -16,6 +16,18 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
functions = {
|
functions = {
|
||||||
|
tmux-refresh-env = {
|
||||||
|
description = "Refresh environment variables from tmux session";
|
||||||
|
body = ''
|
||||||
|
for var in (tmux show-environment | string match -rv '^-')
|
||||||
|
set -l parts (string split -m 1 '=' $var)
|
||||||
|
if test (count $parts) -eq 2
|
||||||
|
set -Ux $parts[1] $parts[2]
|
||||||
|
end
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
kubectl = {
|
kubectl = {
|
||||||
description = "Wraps kubectl in grc";
|
description = "Wraps kubectl in grc";
|
||||||
wraps = "kubectl";
|
wraps = "kubectl";
|
||||||
|
|
Loading…
Reference in a new issue